Problem in code

the for loop is running just once and then it terminates,
can’t identify why.

added comments
increase size of bitset to 10000001