Skip to content

Instantly share code, notes, and snippets.

@llimllib llimllib/

Created Aug 3, 2018
What would you like to do?
def b(integral):
res = []
while integral > 0:
integral, mod = divmod(integral, 2)
res.insert(0, "1" if mod else "0")
return "".join(res)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.