Functional Programming in Scala - Java