DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’» is a community of 963,673 amazing developers

We're a place where coders share, stay up-to-date and grow their careers.

Create account Log in
Cover image for Let's Go: Learn Go in 30 days
Cesar Aguirre
Cesar Aguirre

Posted on • Updated on • Originally published at canro91.github.io

Let's Go: Learn Go in 30 days

You want to learn a new programming language? You aren't sure about what language to choose? Have you heard about Go? Well, let's Go!

"Go is an open source programming language that makes it easy to build simple, reliable, and efficient software". golang.org

Go is a popular language these days. According to Stack Overflow 2020 Developer Survey, Go is in the top 5 of most loved languages. It ranks in the top 3 most wanted languages. Docker, Kubernetes, and a growing list of projects use Go.

Motivation

Go reduces the complexity of writing concurrent software. Go uses the concept of channels and goroutines. These two constructs allow you to have a "queue" and "two threads" to write to and read from it, out of the box. Rob Pike, one of the creators of Go, explains these concepts in his talk Concurrency is not parallelism. In other languages, you would need error-prone code to achieve similar results. Threads, locks, semaphores, etc, ...

Method

Learn something by doing. This is one of the takeaways from the book Pragmatic Thinking and Learning. Instead of watching videos or skimming books, recreate examples and build mini-projects. "Instead of dissecting a frog, build one".

No Copy/Paste. Read the sample, "cover" it and reproduce it without looking at it. If you get stuck, search online instead of going back to the sample. For exercises, read the instructions and try to solve them by yourself. Then, check your solution. Fire up your text editor!

Resources

Before starting, you can have a general overview of the language with Pluralsight course Go Big Picture. To grasp the main concepts, you can follow Learn Go with tests. It teaches Go using the concept of Test-Driven Development (TDD). Red, green, refactor. Other helpful resources to are Go by Example and Go documentation.

β€œTo me, legacy code is simply code without tests.”

― Michael C. Feathers, Working Effectively with Legacy Code

Basic

Intermediate

Advanced

Fullstack

You can find more project ideas here: 40 project ideas for software engineers, What to code, Build your onw x and Project-based learning.

Conferences

Conclusions

Go was design to reduce the clutter and complexity of other languages. Go syntax is like C. Go is like C on asteroids. Goodbye, C pointers! Go doesn't include expected features like inheritance, exceptions or generics. Yes, Go doesn't have exceptions. But, Go is batteries-included. You have included, for free, a testing and benchmarking library, a formatter and a race-condition detector. Coming from C#, you can still miss assertions like the ones from NUnit or XUnit. Aren't you curious about a language without exceptions? Happy Go time!

You can find my own 30-day journey following the resources from this post in LetsGo

Top comments (0)

🌚 Life is too short to browse without dark mode