问题:
I'm just going over some Scala tutorials on the Internet and have noticed in some examples an object is declared at the start of the example. 我刚刚浏览了Internet上的一些Scala教程,并注意到在某些示例中,在示例开始时声明了一个对象。
What is the difference between class and object in Scala? Scala中的class和object什么区别?
解决方案:
参考一: https://stackoom.com/question/7Me1/Scala中对象和类之间的区别参考二: https://oldbug.net/q/7Me1/Difference-between-object-and-class-in-Scala
来源:oschina
链接:https://my.oschina.net/u/4438370/blog/4275638