r/Python • • Jun 23 '14

Writing better python code

https://gist.github.com/kracekumar/09a60ec75a4de19b346e
143 Upvotes

126 comments sorted by

View all comments

2

u/elb0w Jun 23 '14

Why is that called normal code? I would think pythonic is normal for python. I would call that bad code or unpythonic.

Also your default value for functions with a mutable type doesnt highlight the side effect that it causes and why you initialize to None.

4

u/kracekumar Jun 23 '14

Agreed normal code should have been named as bad code. Modified in the gist.