3 ms·
> Comparison: I often program in Python (and teach it) - and while it has its own syntax warts & frustrations - overall the language has a "pseudocode which com
by Aurornis 1y ago
> Comparison: I often program in Python (and teach it) - and while it has its own syntax warts & frustrations - overall the language has a "pseudocode which compiles" approach, which I appreciate.
I think this is why you don’t like Rust: In Rust you have to be explicit by design. Being explicit adds syntax.
If you appreciate languages where you can write pseudocode and have the details handled automatically for you, then you’re probably not going to enjoy any language that expects you to be explicit about details.
As far as “janky syntax”, that’s a matter of perspective. Every time I deal with Python and do things like “__slots__” it feels like janky layer upon layer of ideas added on top of a language that has evolved to support things it wasn’t originally planned to do, which feels janky to me. All of the things I have to do in order to get a performant Python program feel incredibly janky relative to using a language with first class support for the things I need to do.
- morshu9001 1y agoBoth Python and JS evolved by building on top of older versions, but somehow JS did a way better job than Python, even though Py forced a major breaking change. Agree about Rust, all the syntax is necessary for what it's trying to do.
- jamespo 1y agoYou mean typescript?
- morshu9001 1y agoBefore that. The classes and stuff added in ES6 and earlier
- adastra22 1y agoJS is not something I would hold up in high regard.
- mixmastamyk 1y ago> Being explicit adds syntax. Not what they are talking about. Rather better to use words instead of symbols, like python over perl. Instead of “turbofish” and <‘a>, there could be more key words like mut or dyn. Semicolons and ‘c’har are straight out of the seventies as well. :: not useful and ugly, etc. Dunders avoid namespace collisions and are not a big problem in practice, all one char, and easy to read. I might remove the trailing part if I had the power.
- Aurornis 1y agoThis is just personal preferences and familiarity Python using indenting to convey specific programming meaning feels janky and outdated to people not familiar with Python, but Python familiar programmers don't think twice about it.
- mixmastamyk 1y agoNo, it’s not only familiarity. I learned C/C++ in the early 90s, before Python. It’s well studied that words are easier to read than nested symbols.
- yoyohello13 1y agoMaybe it's my math background but I honestly prefer symbols to keywords. It's more up front cost in learning, but it's much more efficient in the long run.
- mixmastamyk 1y agoWhen you are doing multiple operations to multiple variables, and need to see it all at once, math-like syntax still has benefits. But this is not the common case for most programming, which is about detailing business rules. Explicit and verbose (though not excessively) has been shown to be the most readable/maintainable. For example, one character variable names, common in math, are heavily discouraged in professional development. There’s another level to this as well. To me, calculus notation looks quite elegant, while Perl and (parts of) Rust look like trash. Since they are somewhat similar, the remaining angle is good taste.
- deleted 1y ago[deleted]