Key points of this chapter:
• Use an Array if the length is fixed, and an ArrayBuffer if the length can vary.
• Don’t use new when supplying initial values.
• Use () to access elements.
• Use for (elem <- arr) to traverse the elements.
• Use for (elem <- arr if . . . ) . . . yield . . . to transform into a new array.
• Scala and Java arrays are interoperable; with ArrayBuffer, use scala.collection.
JavaConversions. (查看原文)
Programming manuals are like fast foods, you never enjoy reading the book but sometimes that's the expediency. Scala is the official language for Spark, which I should have picked up between 2011 and 2013 if my physical status was much better. I'll ask my S...
(展开)
前段时间学完了coursera上的“Functional Programming Principles in Scala”,现在正在自学“Principles of Reactive Programming”。和这两门课程的内容相比,这本书最大的问题就是对函数式编程的感念介绍太少,书中的内容大都是scala语法类库的堆砌。比如说对foldLeft、fold...
(展开)
0 有用 Lo 2018-05-17 03:14:20
Need to read Programming in Scala next.
0 有用 Vinta 2017-05-29 18:46:43
太魔性了這個語言
0 有用 liuml07 2022-01-01 17:45:39
确实很适合新手快速上手,编排也比较有节奏。“缺点”也很明显,逻辑性差,不适合深入。但是此书达到了它要达到的目的,所以不够深入不算真正的缺点。
0 有用 Momo 2020-12-31 08:58:02
实用
0 有用 催眠 2018-12-11 01:14:41
可惜的是,Scala is not for the impatient :)