Bhavik Bamania

Programming

Why Go?

Bhavik Bamania

3 min read

Share On:

Copy linkShare on FacebookShare on LinkedInShare on ThreadsShare on X
why-gopher
The Go gopher on a hilltop, looking out at hills it hasn't climbed yet, you all must be feeling the same, huh?

Never written a single line of code? That's completely fine, this one is for you. I'm learning Go from scratch and writing it all down as I go: what is go programming language really is, what Go is good at, where it falls short, and why I picked it. I'm no guru, so expect plenty of mistakes along the way.

Let me clear the air before we begin: I'm not a Go expert. Not even close.

I've been writing code for a while now, mostly JavaScript and TypeScript, with a bit of PHP (if you've read my older posts, you already know that). But Go is new for me. On this one, I'm a beginner, same as you.


So I'm learning it out in the open. The stuff that clicks, the stuff that doesn't, and the silly typos that eat my whole evening (herp derp). And I'm writing it so that even if you've never written a line of code, you can follow along. Every new term gets explained when it shows up, no velvet rope.

Okay, enough chit-chat. Why Go?

A language born out of boredom (literally)

Here's my favorite bit of Go trivia. Around 2007, a few engineers at Google were sitting around waiting for a huge program to compile. It was taking so long that they started sketching a new language while they waited.

That language became Go. It went public in 2009, hit its first stable version in 2012, and it's open source, meaning free for anyone to use, read or improve.

Their complaint was simple. The languages they had were either fast but painfully complicated, or easy to write but slow at Google's scale. They wanted both: simple and fast. So they built Go, and they kept it boring on purpose.

Yes, boring. In Go, that's a compliment.

What makes Go interesting

It's tiny. Go has deliberately few features. Most languages give you five ways to do the same thing. Go usually gives you one. That means less to learn, and when you open someone else's Go code, it looks surprisingly like your own.

It's fast, and so is the wait. Go compiles your whole program ahead of time into a single file that just runs. And remember the engineers stuck waiting? Go compiles in seconds, so you change something, run it, and see the result almost instantly.

It's great at juggling. Picture a café with one barista doing every order, every drink and every table. Chaos, right? Now picture ten baristas working together smoothly. Go makes it unusually easy to write programs that work like that smooth functioning café. This is called concurrency, doing many things at once, and it's the reason so much of the internet's behind-the-scenes machinery is written in Go. Tools like Docker and Kubernetes, which quietly power a huge chunk of the web, are built with it.

It keeps its promises. Code written for an older version of Go is promised to keep working on newer ones. Sounds dull until a tool update breaks your whole project overnight. Fewer headaches, more ca$hmonies saved.

Go is the best programming language. Go is a really good language for certain jobs, and if it fit the one you want to do.


Why I picked it

Because it's small enough to actually learn, strict enough to stop me from fooling myself, and useful enough that the time won't be wasted. That's a rare combo.

And I don't want to learn it through endless drills. Learning only from exercises is like learning to cook by chopping onions all day. Useful, sure, but you'll lose interest fast. So we'll learn by making things that actually work, and break, and get fixed and let's see what kind trouble we can make from it?

Next time

We'll install Go and write a tiny first program that makes the computer say hello. Small, but it's the first time you tell a machine to do something and it actually listens. That feeling never gets old.

Have a great time, and see you next time!

GoGolangProgramminggo programmingwhy go

Share On:

Copy linkShare on FacebookShare on LinkedInShare on ThreadsShare on X

Written by Bhavik Bamania

Bhavik Bamania is a software engineer and writer exploring frontend engineering, web architecture, technology, history, psychology, astrology, and culture.

This site uses cookies for basic analytics (page views, no ads). You can accept or decline.