Many programmers coming from other high-performance programming languages, particularly C++, understand the concept of the Standard Templating Library (STL). This library provides common programming data structures and functions access to a generalized library in order to rapidly iterate and write performant code at scale. Go does not have a built-in STL. This chapter will focus on how to utilize some of the most common STL practices within Go. The STL has four commonly referenced components:
- Algorithms
- Containers
- Functors
- Iterators
Being familiar with these topics will help you to write Go code more quickly and effectively, utilizing commonly implemented and optimized patterns. In this chapter, we are going to learn the following:
- How to use STL practices in Go
- How to utilize standard programming algorithms with respect to Go
- How containers...