Cant pass the test cases please help!

hello @haseebshaik00 as the test cases are large in this problem thats why you wouldnt be able to pass the test cases by integer array .
as you have to store only 0 and 1 in the array thats why the bitset array of size 1e6 would be fine enough .
if you still have any doubt please ask here .
i will explain .
Happy Learning !!

still can’t pass the test cases