4 ms·
Every developers should know at least two languages (more is of course better, but two is the minimum for a professional). The optimal way to select: (1) Learn
by goto11 7y ago
Every developers should know at least two languages (more is of course better, but two is the minimum for a professional). The optimal way to select:
(1) Learn the language which is most prominent or employable in your preferred industry (e.g. Java for enterprises, Python for science, JavaScript for frontend).
(2) Learn the language most different to the first, regardless of its popularity and employability. Eg. Scheme if you know Java, Haskell if you know Python, Assembler if you know JavaScript. (There will probably be some disagreement about which languages are to most different to each other, but you get my point.)
- KMag 7y agoI broadly agree with you here. I believe what you're saying is that once you're economically productive in your first language, you get the most bang out of your second language by picking a second language that encourages concepts and idioms not encouraged by your first language. In this way, your second language is really there to improve the way you think about your first language. However, I would word (2) a bit differently, otherwise tons of people will be learning INTERCAL and BrainFuck. For a second language, consider only languages that are at least popular enough to have good learning resources. (This is a pretty low bar... there are probably hundreds of such languages.) Look at which concepts and idioms are encouraged by each language, ignore those concepts and idioms encouraged by your first language, and try and score the usefulness of the remaining concepts and idioms. Do a bit of research reading up on the pros/cons of the idioms and concepts to help you score them. The goal here is to pick up concepts and idioms by learning your second language, which will then diversify the way you think about your first language. I would absolutely look at the machine code generated by one of your languages (or bytecode, if none of your languages compile to native code or have a JIT that can dump out assembly) to understand what's going on, but I wouldn't suggest learning to write assembler as one of your two first languages. Most of the usefulness of assembler can be gained from learning to read it.
- Random_ernest 7y agoA good dogma I think fits roughly in the same category as your opinion is a quote from Alan Perlis: “A language that doesn't affect the way you think about programming is not worth knowing.”
- gustavo-fring 7y agoJS changed almost nothing about how I view languages, nor did it teach me much, outside of what several libraries have. That does not mean it was not incredibly useful to know, both monetarily, and for what it enables me to do, when necessary.
- AnimalMuppet 7y agoAny programing language that does not increase what you are able to do is not worth knowing. That increase may come from greater knowledge, different ways of looking at things, or just from different and/or better libraries.
- CSMastermind 7y ago> Assembler if you know JavaScript Maybe go with Rust instead.
- Koshkin 7y agoI think Python and C are simply a must, whatever the language you use in your daily job and whatever else you might want to learn. You cannot seriously call yourself a programmer if you are afraid of C, and Python is too useful as an ad-hoc tool to be ignored.
- goto11 7y agoI totally disagree with gate-keeping like "you are not a serious programmer if you don't know C". You are a serious programmer if you program stuff that works and achieves it purpose.
- tomp 7y agoIf you don't understand the concepts of C - things like pointers - then you don't actually know how computers work and how programming languages are implemented (i.e. how the JavaScript you write actually happens) so, yeah, you're probably not a serious programmer. Copy-paste code from Stack Overflow? Sure. Debug a complex problem or optimize a piece of code? Unlikely.
- jcranmer 7y agoUnsafe Rust is at least as close to the hardware as C is, if not somewhat closer (C doesn't have 8- or 16-bit arithmetic operations, and I believe unsafe Rust doesn't have the strict aliasing rules of C). Arguing that you specifically have to learn C to understand hardware is the gatekeeping I dislike the most, especially because it turns out that C itself can have a pretty bad view of hardware.
- tomp 7y agoSure, which is why I wrote understand not know. I doubt many Rust programmers would have issues writing C (basically just forget about ownership and write plain functions) unlike say Python or JavaScript (or even Java) programmers.
- AzzieElbab 7y ago