Skip to content

Instantly share code, notes, and snippets.

@9terz
Created September 22, 2018 18:13
Show Gist options
  • Save 9terz/f418b550fc700c9a661ab01c609ccdb3 to your computer and use it in GitHub Desktop.
Save 9terz/f418b550fc700c9a661ab01c609ccdb3 to your computer and use it in GitHub Desktop.
bingap
def bingap(num):
binary = str(bin(num))[2:]
print("binary is {}".format(binary))
numlist = binary.split('1')
return len(max(numlist, key=len))
print(bingap(6666))
@9terz
Copy link
Author

9terz commented Sep 22, 2018

this code failed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment