Joy of Elixir

II. Elixir? Isn't that something you drink?

Elixir the programming language is very different from an elixir which Wikipedia defines as:

a clear, sweet-flavored liquid used for medicinal purposes

And for the programming language variant it says:

Elixir is a functional, concurrent, general-purpose programming language that runs on the Erlang virtual machine (BEAM).

The first explanation seems like it is written in easy-to-understand perfectly-cromulent English. You read each word and you understand it as much as each other word. The second explanation is a stream of words that your nerdy friend would espouse right after pushing up their glasses and they'd probably prefix the sentence with "Well, actually [pause for dramatic effect]".

Sure, some of the words you'd understand, but the rest is nerdy-gobbledegook.

What the devil does "functional" even mean? Does it mean that it works? Well I sure would hope it works! Otherwise, what's the point of this book? May as well close it now. There can't be any use of using a programming language that isn't functional!

Concurrent? What? Things happen at the same time? Why is that important?

What even is an Erlang? Is that like Klingon?

Furthermore, what is a virtual machine and what makes it different from a regular machine? Does it have anything to do with virtual reality?

What is a BEAM? I've seen the Olympics, is it like the balance beam? Or is it like a light beam? Or does it somehow aid in the architecture of buildings? You'll discover later on what it means, but right now it is not as important as the description makes it seem.

It is a sentence very clearly written by one of your nerdy friend's compatriots for all the other nerdy people to understand. They'd all read the sentence and nod sagely and say stuff like "ahhh yes that is correct and succinct and easy to understand". That is because they are nerds and they live this stuff. You are new and we should at least make some effort not to scare you off with such talk!

A Normal-human-friendly explanation is required

Never mind the nerd-compatible explanations of what Elixir-the-programming-language is. Those are written for the nerds. Let's try this one on for size:

Elixir is a programming language that humans use to ask the computer to perform certain actions.

That's a pretty good explanation. I can say that because I am writing the book. I get to write whatever I want: that's how this works. I write, you read.

This new explanation uses simple English words to describe what you would use Elixir to do. It doesn't explain its fancy features using words like "functional" and "concurrent", and it certainly does not mention anything about BEAMs or machines, virtual or not.

The explanation is so good that it could be used to explain any programming language in existence. So it is probably too generic. It's like the black-and-white labelled food you find on the bottom shelf at the supermarket for a dollar. It does the job, but it doesn't quite sit well in your stomach soon after.

Ok, so let's re-vamp it! Simple Explanation Of Elixir The Programming Language, Version Two, here we go:

Elixir is an extremely fun and easy-to-use programming language that humans use to ask the computer to do things. You can write programs that are easy-to-understand for humans and computers alike. Writing Elixir is a joy.

Oh yeah! That's so much better. It gets the people going. Speaking of which, a small crowd of a few hundred people has gathered around. "Joy? I like joy!", they shout. Then they say: "We want to see some Elixir code! Enough talk!". Uh oh, the masses are getting rowdy. I better give the people what they want.