Added some pattern matching

This commit is contained in:
George Petrov 2013-07-29 14:09:11 +01:00
parent 3cc4c64fb7
commit d346342ad6

View File

@ -121,3 +121,25 @@ val text = if (x == 10) "yeah" else "nope"
// Object oriented features
class Person
// Case classes
case class Person(name:String, phoneNumber:String)
Person("George", "1234") == Person("Kate", "1236")
// Pattern matching
// Regular expressions
// Strings
// Input and output