In 2007, Google decided to create a new programming language to replace C++, the Go language. Although it does not replace C++ as desired, it has the similar performance of C and the similar development efficiency of parsing languages and near-perfect compilation speed. Many programmers regard it as "the C language of the 21st century", which is more and more widely used in cloud computing, edge computing, big data, micro services, Internet of things, and high concurrency domain.

Head First Go, written by the author of The C Programming Language and the director of Google's Go team, is a definitive guide to learning Go programming. It's suitable to be used as the teaching material for computer related majors, but also very good for Go language lovers to read. The book consists of 18 chapters, including: syntax basics, conditions and loops, functions, packages, arrays, slices, maps, structures, encapsulation and embedding, interfaces, recovering from failure, sharing, automated testing, Web applications, HTML templates, and more.

Since its official release in 2009, Go has occupied a certain market share due to its extremely high speed and development efficiency. Although designed for high-performance networking and multiprocessing, Go, like Python and JavaScript, is easy to read and use. With this practical, hands-on guide, you'll learn how to write Go code through clear examples. Most importantly, you'll learn the conventions and technologies employers want entry-level Go developers to know.

Table Of Contents

  • 1. let's get going: Syntax Basics
  • 2. which code runs next?: Conditionals and Loops
  • 3. call me: Functions
  • 4. bundles of code: Packages
  • 5. on the list: Arrays
  • 6. appending issue: Slices
  • 7. labeling data: Maps
  • 8. building storage: Structs
  • 9. you're my type: Defined Types
  • 10. keep it to yourself: Encapsulation and Embedding
  • 11. what can you do?: Interfaces
  • 12. back on your feet: Recovering from Failure
  • 13. sharing work: Goroutines and Channels
  • 14. code quality assurance: Automated Testing
  • 15. responding to requests: Web Apps
  • 16. a pattern to follow: HTML Templates
  • 17. Congratulations!: You made it to the end.
  • 18. This isn't goodbye
  • A. understanding os.openfile: Opening Files
  • B. six things we didn't cover: Leftovers

Book Example Codes

Download URLs

Format Download Size
PDF (converted) 94.3 MB
EPUB (original) 113 MB
(Homepage)