Hacker News new | ask | show | jobs
by zubat 3329 days ago
Python, because it's the rare combination of "wildly popular" and "keeps you out of trouble". Ruby has always had a one-framework-town kind of feel to it, with Rails being the one thing people automatically associate with the language. Javascript has the popularity, on the other hand, but it's a minefield in so many ways. The browser is not fun to work with for anything serious, and code written in node bitrots very easily.

So, it's Python. Python has footholds in a variety of places. It's not the most expressive in some respects, but the built in types are more than sufficient to power any student code.

A possible alternate is Go. Go doubles down on keeping you out of trouble by pressing so much code into a uniform style. This may excite some students and frustrate others depending on which threads of thought they're trying to follow.

2 comments

Sounds good, but then someone asks: Python 2 or Python 3? And then you realize python has it's own problems...

Ruby and Python are so similar though just go with one.

Also, a plug for Hanami, because people are still supporting non rails frameworks despite Rails dominance.

http://hanamirb.org/

> but then someone asks: Python 2 or Python 3?

And then you say: It is 2017. Python 3.

Sure, but a lot of useful machine learning libs are still dependent on 2
> a lot of useful machine learning libs are still dependent on 2

If they are a beginner, they would probably start with scikit-learn, which works on Py3.

As does TensorFlow. As does Theano. Etc.

They're not starting with ML, and by the time they would it'll be trivial to "learn" Python 2 as a Py3 programmer.
OP, if you are looking for specific recommendations, this book is free and good: http://openbookproject.net/thinkcs/python/english3e/

If you want to learn web programming, follow it up with this one that is also free: http://chimera.labs.oreilly.com/books/1234000000754/index.ht...

Thanks, I have seen the first book before. The second one looks interesting. I think TDD is a good concept especially from an API design point of view.
For me, the biggest benefit of TDD is it helps me stay focused by creating a similar challenge-effort-success loop to a video game.