Regarding this question


sir can you please check the program
and indentify my mistakes

Hi Sameer.
This is quite a simple question of bit masking. All u have to do is to find the no of set bits.

Have a look at this code. Hope it clears all ur doubts.

Hi, if your doubt was resolved , please mark it resolved
else if u still have any doubt regarding this question, u can post it here : )

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.