

Ask HN: Language Focus - mion

I&#x27;m a young developer looking for a language to focus on. I already &quot;know&quot; a handful of languages, but I&#x27;d really like to master one. My current options are:<p>--- <i>Go</i><p>- Designed by legendary hackers: could learn a lot from their choices; great tools and environment;<p>- Very high performance: less $ spent on servers<p>- Static&#x2F;compiled language: not ideal for things that change too often (eg, startups)<p>--- <i>Lisp</i><p>- According to PG et al, Lisp is the best thing since sliced bread<p>- Somewhat steep learning curve<p>- Not a lot of ppl know Lisp: hard to collaborate, bad hiring pool, etc<p>--- <i>Ruby</i><p>- Great community, lots of libraries &amp; resources, etc<p>- Bad choice when raw CPU performance is important<p>--- <i>Python</i><p>- Swiss-knife: can tackle a wide variety of problems (web, big data, games, etc)<p>--- <i>JavaScript</i><p>- Server &amp; Frontend<p>- A great deal of effort is being put on it<p>- Lots of design flaws<p><i>From a startup founder point-of-view</i>, which of the following languages would I benefit the most from mastering?
======
cpfohl
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.

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

------
cgag
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](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.

------
staunch
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.

~~~
seanmcdirmid
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.

~~~
staunch
> _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.

------
tome
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.

~~~
seanmcdirmid
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.

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

~~~
seanmcdirmid
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.

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

~~~
seanmcdirmid
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...](http://tvtropes.org/pmwiki/pmwiki.php/Main/ArsonMurderAndJaywalking)

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

~~~
tome
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.

------
brudgers
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.

------
dscb
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.

~~~
zck
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.

------
FurrBall
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.

------
lsiebert
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.

------
andrewcooke
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).

~~~
mion
The former!

~~~
andrewcooke
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.

