Range xor cant understand question

can you explain the question…what happened to the array…and where are we inserting the query 0,index L R resemble what?

@Krishna-Singh-2678805765519156
Query 1 means to insert number X at the end of the array
Query 2 means to find a number Y between indexes L and R which gives Max( X^Y )

If your doubt is resolved please mark it as closed

in the given example
5
0 3
0 5
0 10
0 6
1 1 4 6
array is [3,5,10,6]
we have to find y such that 6^y is max
output is 10
thats possible with y= 12 it is not in the array

@Krishna-Singh-2678805765519156
10^6 is 12 which is max possible 6^A[i] where 1<=i<=4
Please read the question and explanation again
You need to find max y^A[i] L<=i<=R

please se the error in the code test case 1 and 2 are not working https://ide.codingblocks.com/s/199765

@Krishna-Singh-2678805765519156
Line 65 and 76
Check for null before going to the node

all the know numbers are inserted! so if right block is not the place to go left must be…so no need to check that stilll even after checking its not workinh

@Krishna-Singh-2678805765519156
I fixed the null pointer issue in your code
Clearly the code went to the node you’re assuming was present but was not so you got run time error
So you need to see what is incorrect with your logic a little as well
Please do that and then we can discuss the question again