Go wasn’t really what I expected it would be. I came into the language thinking it would be a standard general purpose object oriented programming language like C# or Java, but that’s not the case at all. Go is a lot closer to C than either of those two programming languages, but supports object oriented principles. That makes sense as Go was orginally created to fix some of the short comings of C. My week spent with Go showed that Go is a modern, fully featured language that has a lot going for it.

Go Logo

Go is quite a change of pace from the last two weeks featuring Elixir and Haskell. Both Elixir and Haskell are functional languages, have immutable objects, and declarative by nature. Go on the other hand is procedural, imperative, and allows for state updates on values. Moving from the functional languages to Go is a really big difference. I enjoyed the major leap.

Procedural, Flexible, Fast

Go is flexible. It’s compiled, has a garbage collector, statically typed with advanced type inference, and supports concurrent programming. You can even bend the language to use object oriented programming concepts. Go has built for support interfaces and composition which allow developers to utilize encapsulation, message passing, polymorphism, and many of the good parts of inheritance without the baggage that comes with traditional inheritance. Another major selling point of Go is that the compiled package design of Go helps make it fast. Go code typically performs well in benchmarks.

One part of the Go environment that I didn’t like was the repo structure. I didn’t dig too far into the specifics and can’t claim to be expert on this, but the compiler will look for packages only in specific directories. When you build a package, Go will dump a copy of it to your repo and it can then be imported into your other packages as needed. I side stepped this and used “go run file.go” to run my toy programs. This environment behavior is the first thing I would research if I were to start studying Go seriously.

Further Learning Plans

I would like to dig further into Go at some point in the future. I would say that it’s my second favorite language from the challenge, behind Elixir. If I were going to learn Go, I would continue reading The Go Programming Language. I was only able to get through the first four chapters and there is a ton of wisdom to be gained for the book. Beyond that, my next step would be to implement a web service using Go.

Right now I’m not planning to learn Go in 2018 but may pick it back up at some point.

Resources

I was able to pull from a few resources to learn Go this week.

The Go Programming Language by Alan Donovan and Brian Kernighan. This book is the best way to deeply learn Go.
Go Fundamentals by Nigel Poulton. Perfect course to get up to speed on the basics of Go quickly.
Object-Oriented Programming with Go by Martin Van Sickle. This course shows how Go developers can take advantage of object-oriented ideas within their code. This is a very interesting course.

Quick Final Thoughts

Programming in Go is a very enjoyable experience. In the short time I spent with it, Go feels like a more modern C. The number of key words in the language is small and picking up the basics of the languages felt natural. I honestly think I could read through the docker and kubernetes source right now and get a lot out of the experience. I might not understand it all, but it would be a great learning opportunity.