Doubt : XOR function

According to the question we have to XOR " 6 " with a number to maximize it from the given elements of the array.
Therefore according to the given range i.e from 1 to 4 , the only choice we are left with is " 3 ". But the given output is 10 while " 6 ^ 3 = 5 ".

i think L and R are the indexes of the arr
and you have to findt the Y in that rgn
given 6
L=1 and R=4
SO if we take 10
10 ^ 6=12
which is max

hope this will help u
pls rate my work

But the output is given as 10.
And indexing should be from 0 to 3 and not from 1 to 4.

u have to find Y NOT the xor value
and i think indexing 1 se hoge
becoz or koi sense nahi ban raha han qn me

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.