Interpreter for a first-order functional language in Scala