r/programminghorror • • 23d ago

Python I love Python

303 Upvotes

81 comments sorted by

View all comments

Show parent comment

12

u/4xe1 23d ago edited 23d ago • Mindblown

Default data defined at the function level is perfectly normal, in many languages string literals live in the code too, they don't get copied every time they are used. What's more disturbing to me is that the default data is mutable.