Ask HN: What's the Best Language for Learning Core Programming Concepts?
I'd say my most important revelation was discovering that there were underlying concepts I had to learn beyond practical concerns like "how do I do x in y language." These days, it seems to me like there's so many language options for beginners to choose from, and they might all lead you down different roads! e.g. Javascript will introduce you to closures, Haskell to far more advanced functional programming notions, and Java will send you down a pretty OOP heavy path. If you decide to pick up C you'll certainly learn about memory management, but if you stick to high level languages it might never cross your mind! You can write a fairly functional application today without even having a concept of memory addresses, concurrency, compilers, or even stacks and heaps...so much is abstracted away and taken care of for you. Sure, your app likely won't be optimized, but it will still work.
It seems like your choice of language can significantly influence the language spanning concepts you'll encounter. Granting that's the case (or maybe it isn't, let me know why not) what language do you think is best for exploring the conceptual trappings beneath all those functions, vars, and classes? All the substance beneath the sugar?
18 comments
[ 3.8 ms ] story [ 46.8 ms ] threadThere's no language that has all the features, although anything "multi-paradigm" may cover a lot of them.
You might be interested in the "Seven Languages in Seven Weeks" series that throws a lot of languages w/ different programming models at you, then you can dive deeper into anything that strikes your fancy.
However, when stepping back and reflecting on my career, programming, or even CS topics were largely secondary. Study CS as well, but human factors, software engineering, and project management dominated. The Mythical Man-Month and Peopleware are two of the classic works on those subjects. Also, I've been writing an ebook on these subjects you might find helpful. I'll paste the link if anyone is interested.
https://mixmastamyk.bitbucket.io/pro_soft_dev/
I think you should reconsider and ask instead what is the best language to achieve a specific goal.
But to really use them well(creating complex applications that are easy to understand,maintain and extend ) you need to learn object-oriented-design and maybe it's sub-subject domain-driven-design, and those are quite complex subjects on their own and you won't learn them from the language.
https://mitpress.mit.edu/sicp/
For me, and the students I have taught, I think Python is the best language to introduce absolute novices to simple concepts in programming. I then switch to Java and explain the fundamentals of CS from the ground up.
Once a student has a grasp of python and Java they have a simple scripting language and industry standard maintainable language under their belt. They understand all the basic concepts in CS and can extend to new languages and concepts on their own.
The next step would be to use C++ in the application of algorithms and memory management. By starting in python then java, you avoid really interacting with pointers and memory which, in my opinion, makes it easier for students to focus on one concept at a time. Too often in intro classes, it starts with simple concepts like types, but rapidly branches to require the student to understand many concepts at once.
_TL;DR_ Python, then Java, then C++
What are you trying to accomplish? Do you feel there are gaps in your knowledge?
Do you enjoy contributing to open source projects or do you work on something of your own?
I found bruteforcing my way through assembly (On a little PIC) to be of great educational value: Small instruction set, complete control over the memory and you even get to flash some LEDs as well!
If you want to teach Software Engineering (Real world stuff), I think teaching by getting people to do it themselves + being motivated to learn it. Giving a wirlwind tour of language design philosophies and implementations sounds like a good idea. This approach avoids too much focus on a single programming language: Therefore one can really compare the Pros and Cons of using Haskell/ML vs. C++.
C for memory management and pointer juggling
Haskell for static typing, in-depth, and the "purely functional" approach.
Prolog for logic programming
Smalltalk for a sane fully object oriented language
Lisp for programming in a programmable language.