This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Some demo code using Scala | |
import java.util.Date | |
import java.text.SimpleDateFormat // Look ma, no semicolon! | |
// Traits are like Java interfaces, but they can have code in them! | |
trait Age { | |
// This isn't defined, so it's a requirement for inheritors | |
def birth: Date | |