4 ms·
python 3x seems is a milestone, and relatively speaking, python is very readable
by ausjke 7y ago
python 3x seems is a milestone, and relatively speaking, python is very readable
- pjmlp 7y agoPython is very powerful. Reflection, meta-classes, decorators, comprehensions, slots, operator overloading, multiple inheritance and plenty of other features, some of them with semantics that changed across minor versions. Python the full language, is at the same capability level as C++. Many just don't realize it, because it is kind of targeted to teach programming and then people move on.
- slx26 7y agoI'd say that's something Python does well. Many people don't realize because they don't need those features. If you can do with simple code and patterns, go with that. Rust on the other hand, hits you with all the complexity from the start (or a lot of it). I'm not saying this is necessarily bad, or that having a lot of "hidden complexity" is always good, the use-cases are different, but in many cases it's kinda good to not need to know about the things you don't need to use.
- sitkack 7y agoAnd the level of mutation one can inflict upon the runtime is magnificent! http://farmdev.com/src/secrets/framehack/ http://farmdev.com/src/secrets/framehack/ https://github.com/lihaoyi/macropy https://github.com/lihaoyi/macropy
- marmaduke 7y agoRight, you can write your own debugger for Python in Python (assuming CPython).
- sitkack 7y agoYeah, and the cool thing about being able to write your own debugger, you can have domain specific debuggers or debuggers that put the application in the debug state and phone home giving the eng a chance to capture the error and handle it. Lua has a similarly powerful debug hook mechanism. Being able to debug the system from within itself is an amazingly powerful feature.
- treypitt 7y agoSame theoretical capability; inferior performance and safety in general. Its versatility in the stack is, in my mind, its defining characteristic - unlike C++, it's a great scripting language that's easy to get started with- maybe the best. Like C++, it's a capable low-level, close-to-the-metal language. But I doubt it's the best choice for those cases. (We know what Linus said about C++ devs working on the kernel ... what would he say about python devs??) Side bar, I wasn't aware it was a popular educational tool. I was taught type strong languages, and coming into Python felt like writing pseudocode. Too easy, as the Aussies would say!
- pjmlp 7y agoYou are mixing languages with implementations. If CPython devs would care as much as Common Lisp, Dylan, Scheme, Smalltalk, JavaScript, Julia, it surely wouldn't be as slow. There are PyPy, TrufflePython and OpenJ9 Python, they all suffer from the stigma of not being CPython.
- goatlover 7y agoIs it that readable when the code is making heavy use of advanced features like decorators and magic functions, or the code is deep into the inheritance hierarchy?