Scala Tutorial Code