This chapter was an introduction to the implementation of Scala's collections. We started learning about immutable and mutable collections. After that, we discussed Scala's collection hierarchy, where we learned about various super traits such as Traversable
and Iterable
. We also talked about three abstract collection types: Seq
, Set
, and Map
. Then we took a look at the most commonly used collections in Scala. After that, we went the extra mile to learn about all the important functions used to work with collections. Then we learned about how we can convert collections from Java to Scala and vice versa, and found out that it was easy. After that, we discussed which collection to choose from all these options, which led us to consider the performance characteristics of collections.
With this, we've come to the end of part 1. In the next part, we'll start with the object-oriented and functional constructs provided by Scala. The next chapter is about the basics of object-oriented constructs...