News for hackers. Stuff that matters.
Re:FP vs. OO, from the trenches by sampo on Monday July 22, 2013 @06:28PM (#6086887)
> In OCaml, objects can contain mutable values but they must be explicitly marked as such.

Or in Scala, you have to mark object's variables either as `val` (immutable) or `var` (mutable).

Like /u/Fishkins said, the Scala course in Coursera gives some examples of the use of immutable objects ( https://www.coursera.org/course/progfun ). I am sure they are used in a lot of places in Scala code, not only in Odersky's course.

There are no comments on this comment yet.