3 ms·
How do you ensure that you learn the style specific to a certain language and not just literally translate from a language you already know? E.g. in Java, you
by danielh 16y ago
How do you ensure that you learn the style specific to a certain language and not just literally translate from a language you already know?
E.g. in Java, you would probably solve problem 1 with a for loop, while you could use a generator expression in Python.
- eliben 16y agoAnother reason why reading a tutorial or two (or better, five) is essential as the first step. Just jumping to coding programming exercises won't help much in learning how to write idiomatic code for the language.
- dagw 16y agoI'm not suggesting that coding up solutions to PE problems should be done instead of reading tutorials. I mean how are you going to write code if you have no idea how the language works. However I personally find that I learn very little from simply reading a book about a language, I have to write code in it at the same time to help internalize the concepts I'm reading about. And for that I find PE to be a good first step after hello world.