Code Help! | Sololearn: Learn to code for FREE!

+1

Code Help!

I wrote this code that gives the max number of 0's between two 1's in the binary representation of an integer (it's explained in the code file). It was working fine but when I tried other numbers it got some answers wrong. What am I doing wrong? https://code.sololearn.com/cA22A11a26A0/?ref=app

4/9/2021 6:18:29 PM

Sena Tunca

2 Answers

New Answer

+3

Here's an idea https://code.sololearn.com/cG52tysjrSNF/?ref=app

0

thanks to you all!