4 ms·
Huh, I experience python as quite the opposite of "Explicit is better than implicit": - No static types - A variable might belong to the scope of a method, ob
by blauditore 10y ago
Huh, I experience python as quite the opposite of "Explicit is better than implicit":
- No static types
- A variable might belong to the scope of a method, object or class, depending on where it was first set and changed afterwards
- Implicit execution of code on import of a module (__init__.py, including parent packages)
- Any object is truthy or falsey, i.e. conditional statements don't require an explicit boolean
- lojack 10y agoI suppose "dogma" was the incorrect word in that case.
- sweeneyrod 10y agoYou can get the "Python dogma" with `import this`. "Explicit is better than implicit" is part of it, but so is "practicality beats purity" (and "There should be one-- and preferably only one --obvious way to do it, although that way may not be obvious at first unless you're Dutch").