Boolean from array

Hi everyone,

I have problem and hope you can help.

So I have an array

my_array[] {
      object_1,
      object_2,
      object_3
}

also I have booleans

boolean my_boolean_1 = true;
boolean my_boolean_2 = true;
boolean my_boolean_3 = true;

and I have a function with parameters

my_func(id, bla, bla2) {
my_object = my_array[id];

my_boolean_X = false;
}

So the question is how I can put dynamicly my_boolean_X depanding from my_array[id]

Hope I was clear.

Thank you

berlogi:
Hope I was clear.

You weren't. Try harder.

Put the Boolean in an array so you can just use the same index id

Anytime you catch yourself wanting numbers on variable names what you really want is an array.

like this ?

boolean box = {true, true, false, true, true};

box[id] = false;