Pre-SIP: A Syntax for Collection Literals Scala is lacking so far a concise way to specify collection literals. This makes it an outlier compared to many other popular languages. We propose to change this by introducing a special syntax for such literals. The syntax is quite conventional: A sequence is written as a comma-separated list of elements enclosed in square brackets. For instance, here is a diagonal matrix of rank 3: [[1, 0, 0], [0, 1, 0], [0, 0, 1]] This pre-sip is a follow-...
The “we shouldn’t put data in code stuff” is silly. Why do we have Scala worksheets, then? The reason I like and teach Scala is that it’s so flexible and meets you where you are.