What I learned so far on Golang — My Baby Steps

Ana Therese Taroy
2 min readMay 16, 2021

I have been a previous C++ developer and a Java developer for years. I’ve been wanting to learn a programming language each year and this year Golang caught my attention with its continuing rise to fame.

I’m not a very patient learner and would rather get on with the hands-on learning immediately. So here’s my first batch of errors from my baby steps.

It’s sensitive to the placement of your curly braces. When creating a function, have the opening curly braces next to the function name or else…

No unused variables! Good for coding clean. It won’t allow me to declare unused variables.

Declaring variables in 2 ways! I can have a fully declared a new variable or directly use :=. Just remember to declare a variable before you use it!

Printing variables of different data types appended to string isn’t straightforward. As a Java developer, I’m used to appending variables to a string with just a “+”. In Go, you will use Printf if using formatting or use commas.

Finally, no more missing semicolons! I just need a new line for the next line of code. Kinda reminds me of Python.

Golang reminds me of C++ and Python. And I believe will remind me of Java once I get to know it more. I also found it relatively fast to get a code running in no time. Excited to my next Golang adventures.

--

--