3 ms·
Last time I tried to store items in a collection and iterate through them (List in Java), I counted 11 different types I could call it in Scala (List, Seq, SeqL
by deepsun 7y ago
Last time I tried to store items in a collection and iterate through them (List in Java), I counted 11 different types I could call it in Scala (List, Seq, SeqLike, Traversable etc). And different tools.used different ones. It wasn't easy.
- pkolaczk 7y agoI could easily find 11 collection types in Java as well. Any industrial language will have many data structures, because they have different tradeoffs and there is no single container that suits all needs. Scala standard library is a bit in the baroque side, but it has been simplified recently in 2.13.