Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Ask HN: Language Focus
11 points by mion on Aug 1, 2013 | hide | past | favorite | 22 comments
I'm a young developer looking for a language to focus on. I already "know" a handful of languages, but I'd really like to master one. My current options are:

--- Go

- Designed by legendary hackers: could learn a lot from their choices; great tools and environment;

- Very high performance: less $ spent on servers

- Static/compiled language: not ideal for things that change too often (eg, startups)

--- Lisp

- According to PG et al, Lisp is the best thing since sliced bread

- Somewhat steep learning curve

- Not a lot of ppl know Lisp: hard to collaborate, bad hiring pool, etc

--- Ruby

- Great community, lots of libraries & resources, etc

- Bad choice when raw CPU performance is important

--- Python

- Swiss-knife: can tackle a wide variety of problems (web, big data, games, etc)

--- JavaScript

- Server & Frontend

- A great deal of effort is being put on it

- Lots of design flaws

From a startup founder point-of-view, which of the following languages would I benefit the most from mastering?



Go: I actually disagree that it "not ideal for things that change too often". The cost of deploying changes is very low b/c it compiles so quickly. Furthermore, the static typing is extraordinarily lightweight. You have nothing to worry about there.

Lisp: I've only ever used it academically. I'm not fit to comment on it, although my inclination is to say as a founder you should skip it since it's not nearly widely used enough.

Ruby: Works good. (sic) Tons of libraries are a blessing and a curse, though. Also, there's 1000 ways to do everything in ruby...that gets old fast since every library you ever use will chose a different one. All that said, you can't go wrong because of how widely it's used. On the other hand if you're using it solely b/c of rails, then Ruby itself will never really be your main focus.

Python: I have a soft spot for python...I use it to deploy my Go. It's widely used, mature, and I think it's a reasonably good choice. Great for quick file-manipulating tasks as the tools are built in and are easy to remember.

Javascript: Plan on making a web-tool? You're gonna have to learn it. Some of the ugly goes away when you use coffescript. I think you'll need base-level competency at this no matter what other language you choose.

I notice you didn't add C#/Java. C# is actually a really pleasant language to use. The trouble is that you (more or less) have to have a windows back-end to use it.


Thanks for the insights! Yeah, someone told me it's not that bad but I'd rather stay away from the whole Microsoft stack.


If you don't want static typing, Clojure is my recommendation. It's a lisp, but it also emphasis functional programming (common lisp doesn't), has amazing immutable data structure, has nice syntax literals for more than just lists, as well as other nice like destructuring binds. It has great concurrency support (including go-like channels), and it runs on the JVM so it's pretty fast and has access to tons of libraries. Also Clojurescript (clojure to javascript compiler, some example code: https://himera.herokuapp.com/synonym.html) is pretty mature, though you'll have to know the basics of javascript with any cross compiled language.

Though I don't necessarily agree with you that static typing isn't going to be good in a startup environment, I'm just getting into playing with static languages (Haskell) myself so I can speak strongly on the matter. In that domain though, I think Haskell/Ocaml and even Scala are better choices than Go.

If you do want to learn Clojure, the O'Reilly book "Clojure Programming" is excellent and the best out there for beginners. You should easily be productive after reading that, it's pretty comprehensive. The Joy of Clojure would be a great follow up though. The #clojure channel on freenode is very friendly as well.


I think every programmer should know one of Ruby/Perl/Python very well because they're by far the most versatile type of language. It's pretty rare that you can't solve a problem in one of them, even if when it's not the best tool for the job. It truly doesn't matter which, whatever feels the best to you. It's not a technical choice.

If you want to do Lisp I think Clojure is a really exciting option. It's modern and runs on the JVM, which is a big advantage for some people.

You can learn basic Javascript in a week, which is all you really need for most web development tasks. Most web apps are a sprinkle of Javascript, though that is not the case with every app.

Javascript, Ruby/Perl/Python, and Go are a pretty killer combo. You'll have trouble finding problems you can't solve with that set.


Ruby/Perl/Python...which one out of the three doesn't belong? I mean, Ruby and Python are definitely comparable, but Perl is meant for something else entirely.

>It's pretty rare that you can't solve a problem in one of them, even if when it's not the best tool for the job.

All of these (and most other) languages are Turing complete, so what does this even mean? I can solve any problem in assembly code also.


> Perl is meant for something else entirely.

No, in fact Perl/Ruby/Python are virtually identical in a technical sense. They're capable of, and intended for, exactly the same kinds of applications.

> All of these (and most other) languages are Turing complete, so what does this even mean

It's very obvious what it means, you're just being intentionally obtuse.


Perl fits in fine in terms of usage, and can do everything that you can do in the other two, and probably more. It's the employability of perl hackers vs python and Ruby programmers that suffers.


Personally I do not enjoy using poorly-typed languages (C, C++, Java) and prefer the flexibility of untyped languages (Python). However I even more prefer the flexibility and strength given by powerfully-typed languages (Haskell, and I suppose Scala, OCaml, F#).

Don't confuse typing with rigidity.


Java as a poorly typed language along with C and C++? Wow. Java's type system isn't "flexible", but its far away from unsafe.


I wasn't claiming anything about safety, but now you mention it, yes it is unsafe. Nullability is one example.


This is like claiming a scratch and decapitation are the same thing. Haskell is unsafe too, then, there are plenty of dynamic hazards even with BSDM static typing in place.


Not sure how to respond rather than just to say I am of the polar opposite opinion.


Probably.

Let's put it this way. Let's say your example of bad leaders was Hitler, Mao, Stalin...and Jimmy Carter. Surely they all made mistakes, but one of them doesn't belong in the "set" of the others. Java does provide safety at run-time in the case of dynamic hazards, the same cannot be said for C/C++. C/C++ are a different level of evil lacking even run-time safety, so its weird, and perhaps intellectually dishonest, that you would lump them all together as "unsafe." Anyways, there is a name for this trope [1,2].

Now take your safest language, I guess that would be Haskell, even Maybe doesn't eliminate all dynamic hazards, especially if there is no way to cover from the Nothing case (it just makes you check everything, it doesn't eliminate the problem).

[1] http://tvtropes.org/pmwiki/pmwiki.php/Main/ArsonMurderAndJay...

[2] http://tvtropes.org/pmwiki/pmwiki.php/Main/AllCrimesAreEqual


I didn't put Java in the same group as C and C++ regarding safety. I just pointed out that they are all "poorly typed" by which I mean they have rigid, inflexible, awkward to use typing.

I agree that Java is safer than C and C++, mostly by virtue of not having pointers. However I would say that Haskell is safer than Java by a far greater degree than the degree that Java is safer than C and C++. You can encode many, many more invariants in types.

As to Haskell being unsafe, of course it is to some degree, since you can't encode, say, termination in the type system. But I'd have to know what specific examples you have in mind before responding further.


I think the question is incompatible with the constraints. From a founder's point of view, there's no reason to master any language, let alone a new one. What matters is being just good enough at something to start iterating.


I think the better tactic is to focus on mastering programming and solving problems, rather than a specific language.

Learning a new syntax is not that challenging, and no language will be the optimal(or even possible) to use for every project.


That's the thing, though -- languages aren't just changes of syntax. Writing in an object-oriented style is very different from writing in a functional programming style, even within the same language.

Alternately, new libraries are worth learning. Learning how to deal with massively parallel code is very different from singlethreaded programs.

Of course, you can write C in any language.


Personally I would go with Lisp. The symmetry between data and executable code affords flexibility beyond compare. You have a first class suite of tools with Emacs + SLIME + Paredit. You have native deployment on multiple platforms to boot. Can't go wrong.

If you prefer static typing I'd choose C++ over Go. Good old C++ may not be the flavor of the week but it is almost as dummy-easy as Java if you use smart pointers and RAII. It has excellent generics support, something sadly missing from Go. Great mutli-platform native deployment.


Are you working? If not, pick a language you can get work in, work that you want to do. Even if you are in school, at some point you won't be, and you will want to have projects in your portfolio, and skills you can leverage to get work.

Other languages will be around for later. You can learn Lisp while working in python , but knowing lisp probably won't get you the freedom to master python after work.


is the idea that you want to be a founder, and are asking what language would best help you, or are you asking founders what kind of people they want to employ?

if the latter just check the hire threads (at the start of each month in "ask" there is a thread about who is hiring).


The former!


oh, in that case it seems it seems like you want something to hack out a minimum viable product (i am no entrepreneur i just learn this bullshit from reading hn). in which case, if it's web-based, ruby+rails or python+django. if it's mobile then i am unsure.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: