In this class, we will cover the key architectural and design aspects that distinguish Go from other imperative languages, including Go's approach to object oriented programming and concurrency. We will also learn how these characteristics make Go a strong choice for applications that demand fast development, reliability, and scalability.
Full lesson material, taught over multiple two-day courses, can be found in the Ultimate Go section. Please see the gotraining README for contact information.
Examples marked with an asterisk are from golang.org, provided under a BSD license.
For a great talk/video that reinforces many of these ideas, see Andrew Gerrand's Code that Grows with Grace.
Easy to learn and reason about, trivial to machine-process.
Variables, Builtins, and Type Safety (Source)
Safe and simple. Strings and slices solve many traditional pointer use-cases.
Peano Pointers (Source) *
Allow your code to grow gracefully without you.
An extension/wrapping mechanism based on composition, not inheritance.
Embedding and Interfaces (Source)
Goroutines and channels for convenient and safe concurrent algorithms.
Concurrent Pi (Source) *
Concurrent Prime Sieve (Source) *
Excellent value for its volume. I/O is especially powerful.
Behavior As Error Context (Source)
Basic cURL) (Source)
Universally adopted formatting, testing, and build tools. Many analysis tools are available (and custom tools are easy to write).
All material is licensed under the Apache License Version 2.0, January 2004.