3 ms·
Python is not readable to you? The beginner friendly, whitespace-enforcing, almost-like-pseudocode-in-English language - that Python? - is not readable enough,
by optymizer 4y ago
Python is not readable to you? The beginner friendly, whitespace-enforcing, almost-like-pseudocode-in-English language - that Python? - is not readable enough, but Rust, where you liberally sprinkle ', {}, !, &, :: or #[] everywhere _is_ readable to you? You must be trolling.
You know what Rust looks like to me? Perl without the dollar signs. There's your write-only language, you just have it backwards.
- zozbot234 4y agoSurface syntax is the most subjective aspect of a programming language, but Rust uses just a few symbols in a very consistent way. It's nothing like Perl. The indentation rule is nice for small examples, but it tends to break down in cases that are even slightly complex. Which is why, e.g. Haskell can use semicolons and curly braces as an alternative.
- insanitybit 4y agoIn terms of parsing, sure, Python may be slightly simpler. In terms of mentally interpreting the code? Absolutely Rust wins.
- drogus 4y agoBeing able to understand the syntax and by implication being able to understand a single piece of code in front of your eyes doesn't mean you will understand what it actually does. If you're talking about a small piece of code mainly using well known APIs, maybe you will understand it perfectly. But with code calling custom functions in a big codebase? Even when looking at a simple function call in a class: - if it calls a function on `self`, where is it actually implemented? - if you pass arguments, can they be mutated? - can the function throw an exception? you can't really answer this questions easily and I would argue answering them in Rust is much easier. Also because tooling for statically typed languages can derive much more than for dynamically typed languages.
- kika 4y agoHow does pattern matching looks like in Python? No, not 3.10 :-) The 99% of Python code that I have to read at a random company is barely 3.7