5 ms·
As with natural languages, if you want to learn language X, go learn language X and don't try to learn Y first. So if you want to learn Rust, learn Rust. In my
by hsivonen 8y ago
As with natural languages, if you want to learn language X, go learn language X and don't try to learn Y first. So if you want to learn Rust, learn Rust.
In my experience, particular theory as in CS papers isn't needed for learning Rust. Understanding the runtime stack, RAII from C++ and malloc/free from C helps, but if you haven't already programmed in C and C++, it doesn't make sense to learn them in order to learn Rust. Any introductionary lecture on how the runtime stack works combined with the abstact idea of pointers to heap should be enough (no need to know how heap allocation works in detail).
- giancarlostoro 8y agoIdk having learned Python for 4 months it helped when I transitioned to JavaScript. A lot of things I knew how to do in Python I tried in JS and they seemed to work. It certainly helps to learn similar languages, and in my opinion it never hurts to know more programming languages. :)
- undseg 8y agoWhile everything you said is true, imagine your final goal was to learn Javascript: going through Python wouldn't help significantly. I feel that was the point of parent. Certainly, learning your first language (or first language in a certain paradigm) is a whole different matter than picking up a bunch of other similar-looking ones.
- firethief 8y agoThat's an interesting choice of analogy; there's some evidence that's not necessarily the best approach: https://en.wikipedia.org/wiki/Propaedeutic_value_of_Esperanto https://en.wikipedia.org/wiki/Propaedeutic_value_of_Esperant...
- yorwba 8y agoNo, there isn't, at least not in that article. If you actually read the studies referenced, you'll notice that none of them actually support the claim that learning Esperanto first is better than just starting with your actual target language directly. Learning Esperanto can speed up learning another language with shared vocabulary, but not so much that it offsets the initial time investment of learning Esperanto. Given how often it seems to be used to perpetuate dubious claims about Esperanto's almost-magical benefits, I'll need to find some time to completely rewrite that Wikipedia article. For now I'll just link to a review of one of the studies I wrote up a while ago: https://news.ycombinator.com/item?id=14848019 https://news.ycombinator.com/item?id=14848019
- TJSomething 8y agoI can't find it right now, but I've read a study that showed that teaching Python and then another language yields better understanding then just jumping into the harder language. I was able to find the article "What About a Simple Language? Analyzing the Difficulties in Learning to Program" by Mannila, et al., which found that first time programmers found it easier to write bug-free programs in Python than Java and subsequently had a lot less trouble with the details of Java after learning Python, as they did not have to use the mental bandwidth to learn the most basic concepts of programming while also learning static typing and the incantations required to use Java.
- hsivonen 8y agoAs the very first language Python may be a good choice compared to Rust in the sense that one can learn to _program_ with a smaller risk of such up-front frustration as to give up altogether. However, after getting to the point of feeling “I can do this programming thing”, I don't think Python provides any specific help for learning Rust more efficiently than learning a given thing in Rust directly.
- kungtotte 8y agoI think it's sometimes difficult for those that already know how to program to look back and realise what it feels like to not now anything about programming. When you're starting out you're really learning three things at once: General problem solving, the vernacular and methodology of programming (what's a variable, a function, control structures, how is a program run, what are expressions and statements, etc.), and finally the actual language itself. The first two are universal across languages, but the third is very different depending on what you pick. A language like Python makes that part much simpler than a language like Rust. There's fewer hoops to jump through, less to keep track of, and you can dive in applying your newfound knowledge of the first two topics.
- mic47 8y agoUnless the target language is functional language. Actually, prior experience in imperative languages makes it harder for you to move into functional programming language, as you have to unlearn some things.
- nazka 8y agoI agree with hsivonen that knowing about "the runtime stack, RAII from C++ and malloc/free from C helps". Maybe learning common problems with pointers and what they are will be good to do. After that you are good to learn Rust.