Queries to find the maximum Xor value between X and the nodes of a given level of a perfect binary tree
Given a perfect binary tree of N nodes, with nodes having values from 1 to N as depicted in the image below and Q queries where every query consists of two integers L and X. The task is to find the maximum possible value of X XOR Y where Y can be any node at level L. Examples: Input: Q[] = {{2, 5},