Live data from Hacker News

Learn more programming languages, even if you won't use them

thorstenball.com

251–260 of 319 posts

Re: Learn more programming languages, even if you won't use them

#251
Why should anyone learn the reference manual of a man-made tool they suspect they won't use, when there are yet unlearned reference manuals for tools they will use?

Should people also read the instruction manuals for appliances they have no intent of buying?

An applicance maker should do that, to find ideas to steal. That's about it.

When it comes to learning for the sake of learning, there are more wortwhile things in the world. Learn a foreign language, for instance.

Re: Learn more programming languages, even if you won't use them

#252
I learned just some rudimentary Haskell. It tends to force you into a kind of bottom-up-test-as-you-go approach, which can work pretty well when you have no hidden state. The next time I wrote a shell script, I did it like that, and started writing much better shell scripts. It also surprised me how much easier that flow worked with the shell than with Python, even with Python's REPL. To do the equivalent thing in Python, testing functions nearly interactively, I had to do something like import module; reload module; from module import * over and over. At the shell prompt, I just kept hitting the up arrow to source the script I had just saved so I could try out the new function.

I wrote a trivial amount of Haskell, and it still changed how I write shell scripts, which I didn't expect at all.

Re: Learn more programming languages, even if you won't use them

#253
post #94

Earlier quoted context omitted.

The OP wasn’t talking about Japanese. They were talking about European languages- many of which share a common heritage

Not all of them do, but the ones mentioned were all very similar Romance languages.

I’m aware not al of them do. This is why I said “many” and not “all”.

There are roughly 3 main groups of European languages: Italic (or Romance as you described it) for Western Europe, Germanic which is predominantly Central Europe, Scandinavian countries and the UK; and Balto-Slavic for Eastern Europe. Generally speaking of course.

However there is still a fair amount of cross pollination even with the Germanic and Italic languages, not to mention shared characteristics (not least of all a shared alphabet) that doesn’t exist with Japonic languages such as, well, Japanese.

Re: Learn more programming languages, even if you won't use them

#255

Earlier quoted context omitted.

Agreed. And to address the grandparent comment. Its entirely possible that he is approaching his coding with a professional mindset and wasting time on things like maintainability, scalability, or similar just out of habit.

It’s a waste of time to use classes , if all you’re doing is hacking together 500 lines into a stable enough heap to generate the graphs for a paper. Not all academic code is that bad, but the heft is definitely towards that end of the pool. I got really familiar with the distinction, because I spent a while translating PhD project/demo code into actual products for $JOB. It’s definitely mostly in making things secur…

This a thousand times over. Academic code will take every shortcut and simplification possible. Hardcoded values, globals, no modularity, no error checking, shared-everything architecture assumptions, single-letter variables with mixed naming convention, anything to get the job done.

Once the paper is written, the data analyzed, the project is done. There is no such thing as "maintainability" because the code isn't used past publication.

Re: Learn more programming languages, even if you won't use them

#256
post #255

Earlier quoted context omitted.

It’s a waste of time to use classes , if all you’re doing is hacking together 500 lines into a stable enough heap to generate the graphs for a paper. Not all academic code is that bad, but the heft is definitely towards that end of the pool. I got really familiar with the distinction, because I spent a while translating PhD project/demo code into actual products for $JOB. It’s definitely mostly in making things secur…

This a thousand times over. Academic code will take every shortcut and simplification possible. Hardcoded values, globals, no modularity, no error checking, shared-everything architecture assumptions, single-letter variables with mixed naming convention, anything to get the job done. Once the paper is written, the data analyzed, the project is done. There is no such thing as "maintainability" because the code isn't u…

In mathematical code, single letter variables are often the clearest. "Descriptive" names only obfuscate the meaning further, because the meaning is in the math.

Re: Learn more programming languages, even if you won't use them

#257
post #105

Learn more ? I'm actively trying to unlearn a bunch of languages at this point! ofcourse, when I was a wageslave in the bay area, its nice to know python, java, javascript, scala etc. - got me jobs every 2-3 years & put food on table. now that i'm in academia, its completely upside down. literally everybody is way more productive than me in just about any task. The other day I as supposed to program a poisson clock,…

why don't you share the code that they wrote? I'm interested in seeing the code produced by people in academia. Anyway, once you reach enough mastery in your craft using one language or another is just a difference in deciding what level of abstraction you can work at and this is determined by performance requirements.

"The code produced by people in academia" is about as specific a target as asking about the diet of people in Portland. It ranges from a strict regimen of Taco Bell to pesca-pescatarian.

Re: Learn more programming languages, even if you won't use them

#258

Would love to see a list of sample projects for each common language that plays to its strengths. Often if trying to pick up a new language in my spare time, I can get to a stage of learning the syntax, but if I do it by following a "101" tutorial, I'll end up building another To-do app or whatever — it's very hard from an "unknown unknown" position at the start to find the path into idiomatic "X" that will show you…

I too would really enjoy some sort of “Build X in Y” type of resource for this.

Re: Learn more programming languages, even if you won't use them

#259
post #255

Earlier quoted context omitted.

This a thousand times over. Academic code will take every shortcut and simplification possible. Hardcoded values, globals, no modularity, no error checking, shared-everything architecture assumptions, single-letter variables with mixed naming convention, anything to get the job done. Once the paper is written, the data analyzed, the project is done. There is no such thing as "maintainability" because the code isn't u…

In mathematical code, single letter variables are often the clearest. "Descriptive" names only obfuscate the meaning further, because the meaning is in the math.

I've translated several mathematical papers into code, and I must strongly disagree. The very first thing I do is translate glyphs into names relevant to the domain I'm applying the math to. It makes the rest of the process immensely easier.

Re: Learn more programming languages, even if you won't use them

#260
post #98

Earlier quoted context omitted.

I thought I was the only one. Also class and method names : is it array.length(), array.len(), array.Length, array.size(), len(array), Len(array).

This is one reason I love PowerShell's design that everything is case insensitive. For casual scripting, it's so nice to not have to care if it's length or Length. At least memory can help me if it's len/length but length/Length is no distinction at all. (Case sensitivity is one of my pet hates, for anti-human UX).

Interesting. I've come to basically the opposite conclusion and find case insensitivity to be counter intuitive. "Foo" and "foo" are not the same set of ascii characters; why should they map to the same thing?
Post reply on HN