Please take a look towards my code :- help me to solve errors in my code

@anshulgurawalia
at line 9 it should be number = number>>1 you are not updating number with new number.
initialize result inside loop for test cases so that it could start from res = 0 for every test case.
and pass “i” to bitscount function you are passing “a”

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.