您只需记得Scala像许多函数语言一样允许使用代码块(aka函数)作为参数并根据需要使用它们即可。
You just need to remember that Scala, like many functional languages, allows you to take blocks of code — aka functions — as parameters and apply them as desired.
And I don't quite remember from reading or from class how big these things are, well, it turns out -- and this is sometimes useful, later on more likely than now -- but C has a size of operator that takes an argument in parenthesis and it will tell you how much space is used to store that particular data type.
我不太记得类中的这些类型,是多大的,嗯,结果是--这个在以后比现在,可能是更有用的--不过C语言中有个sizeof的操作符,其中括号里有一个参数,它会告诉我们,要存储一个类型的数据,需要占用多大空间。
应用推荐