Skip to content

Commit 1371de2

Browse files
authored
Fix 067_Add_Binary for Python 3 (qiyuangong#35)
* Fix 067_Add_Binary.py for Python, @yuchenliu15
1 parent 0c59028 commit 1371de2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

python/067_Add_Binary.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def addBinary(self, a, b):
5353
if (lsb + pos) >= 0:
5454
curr += int(b[pos])
5555
res = str(curr % 2) + res
56-
curr /= 2
56+
curr //= 2
5757
pos -= 1
5858
if curr == 1:
5959
res = '1' + res

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy