have no idea why my for loop goes only till i=1
for(i=0;i<n;i++)
{
if((a[i]&mask)!=0)
{x= (x^a[i]);
cout<<x<<endl;}
}
and i am not getting the rite answer
Unique number 2
the loop u mentioned, worked alright
however the previous while loop has to be
while temp&1 != 1 and not 0 because u need the first set bit not the first clear bit in the logic
if your doubt is solved, please mark it as resolved