Skip to content

Instantly share code, notes, and snippets.

View botekchristophe's full-sized avatar
🏠
Working from home

Christophe Botek botekchristophe

🏠
Working from home
  • Lookout Inc
  • Calgary, AB
View GitHub Profile
import scala.collection.mutable.ListBuffer
case class User(firstName: String,
nickName: Option[String] = None,
lastName: String,
happiness: Option[Boolean] = None,
age : Int)
val allUsers: ListBuffer[User] = scala.collection.mutable.ListBuffer.empty[User]
allUsers += User("Calvin", Some("Murican"), "Ference", happiness = Some(false), age = 78)
case class User(firstName: String,
nickName: Option[String] = None,
lastName: String,
happiness: Option[Boolean] = None,
age : Int)
val allUsers: List[User] = List(
User("Calvin", Some("Murican"), "Ference", happiness = Some(false), age = 78),
User("Max", Some("Mad"), "Millette-Coulombe", happiness = Some(true), age = 12),
User("Johann", lastName = "David", age = 26),