Fluent in 3 months: Javascript

Week 1/12

Maxene Graze
3 min readOct 1, 2020

9.21.2020

I love communication. I never studied it as a field in itself, but it made an appearance in all the domains I studied: as an undergraduate, I double-majored in Foreign Languages and Biology, where my niche fascination was cell communication. I pursued Linguistics for my masters degree, studying the science behind the foreign languages I learned and will never learn. Today, I am studying programming, the communication of technology.

I always thought I would study Ancient Greek when I retired because no one “speaks” Ancient Greek: there’s not really phonology or phonetics for you to master like learning a living language, so I wouldn’t need anyone but myself and a lot of free time. Programming languages are kind of like that, without Homer’s epics, of course. You still need to learn morphology and semantics, but you can sidestep phonetics, phonology, and pragmatics. It’s a good thing to study when you are stuck at home during a pandemic because all you need for immersion is a computer; no plane ticket is involved.

I would be lying if I said I would have preferred to spend my shelter-in-place days learning coding languages over Ancient Greek. In the end, knowing Ancient Greek doesn’t bring home the fancy organic bacon (I’m sure it won’t be a surprise to hear that software engineers make on average three times more than Ancient Greek teachers, and there’s no advanced degree required), and only software engineering seems like it could unite my myriad passions. So, stuck in a small town in California, complete with a “Main Street” and a “Church Street,”, I started a software engineering boot camp. Eleven hours a day, six days a week; I’m destined to learn something at the end of its three months.

9.23.2020

Maybe this is no surprise to anyone else, but programming languages are superfluous too: there are synonyms. For example, we learned about tests today:

Chai, a library used to test code, claims that the choice between using “should,” “expect,” and “assert” allows for “expressive language.” In other words, these words have the same output, but if you are feeling really confident, you might employ assert’s structure, or if you’re feeling a bit partial, you could opt for should’s. The language you use is entirely up to you and the style you’re drawn to — like choosing to say “excessive” over “superfluous.” I opted for the assertive option to give me a confidence boost.

9.25.2020

I used to make a sharp distinction between programming languages and human languages, but since programming languages are created by humans, I don’t feel very comfortable with these differentiating terms. I’ll try out “natural languages” vs “programming languages” and see how that feels.

9.26.2020

Like natural languages, programming languages are subject to an equivalent of grammaticalization, basically language change. This seems pretty intuitive since technologies are currently evolving and being improved upon.

I noticed a few analogies this week revolving around:

phonetic erosion: essentially a reduction or omission of certain sounds in a given statement.

A classical example from English:

‘Going to’ → ‘gonna’ (or even ‘I am going to’ → ‘I’m gonna’ → ‘I’mma’) and ‘because’ → ‘coz’

And in Javascript:

// Function expression
const greet = function(who) {
return `Hello, ${who}`;
}

becomes

const greet = (who) => {
return `Hello, ${who}!`;
}

where ‘function’ is omitted in favor of an arrow. My favorite example of programming language phonetic erosion is the introduction of the ternary operator, which replaces some syntax with punctuation.

var age = 19; 
var canDrive;
if (age > 16) {
canDrive = ‘yes’;
} else {
canDrive = ‘no’;
}

becomes

var age = 19; 
var canDrive = age > 16 ? 'yes' : 'no';

It’s like shortening,

“There’s canDrive. If the age is greater than 16, canDrive is yes. Otherwise, canDrive is no.”

=>

“Is age more than 16? canDrive is yes, otherwise it’s no.”

The “erosion” version of the Javascript is less verbose and more concise just like its translated counterpart!

--

--