Created
February 3, 2018 04:10
-
-
Save igauravsehrawat/846d7ee444855f9519acc17dd109f87c to your computer and use it in GitHub Desktop.
Brain teaser
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def foo(i, a=[]): | |
a.append(a.append(i)) | |
return a | |
for i in range(3): | |
b = foo(i) | |
print(b) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment