Hacker News new | past | comments | ask | show | jobs | submit login

Maybe some analogy - C is like riding a very fast bike. Python, Java - Starting a truck which will move what you want. Erlang - starting a railway system.

Erlang is like another system inside your system, it's more akin to booting a system inside a vm just to echo some hello world.




This.

Erlang isn't a bare programming language like C, or even a high level, but still fundamentally simple language like Python.

It isn't just an intermediary bytecode running in a VM, like Java, that maps bytecode instructions to OS instructions.

It is instead more like a Smalltalk environment or similar; an entire ecosystem running for the specific purpose of providing you a very particular kind of programming environment.


Terry Davis describes his TempleOS† as a motorbike, Windows a car and Linux a semi truck with a huge gearbox. In TempleOS, you'll crash if you lean over too far. The solution? Don't lean over, then!

† ring-0 only, no memory protection, exploratory dev/art focused


Exactly.

To put it another way, if you run code on a system with concurrency units sharing the memory (the heap), your code is running on DOS or Windows 3.1 which was cool in 1990s.

Erlang/Elixir is like running your code on a modern OS with a process memory separation, preemptable concurrency (processes don't have to yield by hand to others). Built in tracing and monitoring facilities (tracing, observer, dbg). Built in networking (distribution, global process registration, in memory distributed db) etc.


By default, the erl interpreter starts up the otp app, which loads lots of modules (50+?) and multiple (5?) different processes. It takes a second. To get things running faster, you can use the -boot argument to erl. There is a appendix in Joe Armstrong's book that steps you through it.


yeah, also it would be fair to compare a running actor system with Akka (jvm, java, scala), CAF (c++), XUDD (Python), Celulloid (Ruby) vs Erlang

I believe Erlang would do some interesting things there


Bike as in motorcycle, not bicycle I presume?


It depends IMO, small c programs - bicycle, bigger ones - motorcycle. If you want to extend this further, C can be any bike or even a road (linux).


I'd say C is the bicycle and C++ is the motorcycle. Both give you plenty of chances to kill yourself.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

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

Search: