6 ms·
Can you clarify your meaning? I'm a little confused. It sounds like you say "Rust isn't really a beginner's language... it's probably easier to teach [Rust] as
by squiggleblaz 9y ago
Can you clarify your meaning? I'm a little confused. It sounds like you say "Rust isn't really a beginner's language... it's probably easier to teach [Rust] as a first language than a second after Python or Java". At first it sounds like a contradiction but when I inspect closer I realise there's alternative interpretations.
Do you mean "learning a system's programming language is not helped and may even be hindered by experience with general purpose languages"? Are there any good beginners' systems languages, which help Rust?
- steveklabnik 9y agoI think your parent is saying "Rust isn't a great language to learn programming with", that is, if you've never programmed, Rust is not a great choice. I agree, but I don't think it's inherent; I think it's a lack of resources targeted at this demographic.
- syeaj 9y agoWhile the book is really top notch (I'm usually not a fan of programming language books), there's something to be said for not introducing all concepts at once. A scripting language has many of the same concepts, but not lifetimes, etc. Not to say objects are intuitive!
- steveklabnik 9y agoThanks! While this is true, those languages have stuff Rust doesn't as well. Take Ruby, for example: Rust doesn't have method_missing, or eigenclasses, or inheritance. "How do I know which method gets invoked" is much more complex.
- syeaj 9y agoOkay, I yield. I think you may be right. I've been thinking a lot about how I'll teach my children STEM topics and I've grappled with the idea of teaching Rust. One of the things I like about it is that you know the behavior at compile time, unlike Ruby or even C.
- curun1r 9y agoI do think a lot of it is inherent in the design choices that Rust has made. Rust, as a language, has a fairly large surface area. There's a lot of different syntactical and conceptual lessons that need to be learned by new Rust programmers. Compare that to, say, Lisp. My first programming class at Berkeley was taught in Scheme, which is basically Lisp. Within the first 20 minutes of the first day, the professor had not only gone over a bunch of introductory announcements, but he'd also introduced us to every bit of syntax we would learn in the course. The second lecture covered car/cdr and recursion. Beyond those two lessons, everything we learned was about the practice of programming, not the language we were programming in. Rust occupies a fairly unique position of being high level, with lots of abstractions to make experienced programmers more productive, and low level with fairly precise control over lower-level hardware concerns. That's really impressive, but I do believe that impressive power comes at the cost of an unavoidable learning curve. You'll never get a backhoe to be as simple to operate as a shovel. Which isn't to say that there isn't ample opportunity for the work that you and Carol are doing to make learning Rust easier--beginners now have it much easier than people like me that jumped in around 0.8. But it is to say that I don't think it's possible to ever make Rust as easy to learn as conceptually simpler languages. If I were designing a CS curriculum, I'd start new students with a Lisp dialect, then move on to Assembly (which, while hard, provides what is, to me, an essential view of the actual hardware that you're using) and then move on to the more practical languages. I'd still like to teach Rust, but it would come later to help introduce advanced concepts like compilers and operating systems.
- steveklabnik 9y ago> Compare that to, say, Lisp. This makes me think of the module reform RFC: > In other words, while there are simple and consistent rules defining the module system, their consequences can feel inconsistent, counterintuitive and mysterious. See also Rich Hickey's "simple made easy." I do think Rust has some inherent learning curve, but I also don't necessarily agree with this framing. Simpler languages aren't always simpler to actually write software in.
- curun1r 9y ago> Simpler languages aren't always simpler to actually write software in. I completely agree with this. But when you're learning to program, the goal isn't to write software. It's to learn the lessons and concepts that will one day allow you to write software.
- baq 9y agoSteve got it right. I'll clarify nevertheless: Rust and computer architecture (caveats apply) are (IMHO) very good subjects to be taught in tandem, as Rust tries very hard to provide safety features and high level abstractions that are impossible to implement in general, but quite possible in special, if very common, cases. Seeing where it is possible and where it's not and why should be an eye-opening experience. The operative word here is actually 'taught' - I think it's just too much stuff to internalize to be able to read a few tutorials and get it. It's a topic for multiple semesters of structured teaching going together with lots (lots!) of practical excercises. In that sense, it's easier to be taught if you don't know anything about programming than if you have a wrong mental model of how programming languages work, because you have to unlearn it first or open your mind in some other way for a different way of doing things. (The post that I was replying to asked why would you want four different string types - and you actually need at least six to interact with C libs and the OS...)