// closure example def m2: Int => Int = { val factor = 2 val multiplier = (i: Int) => i * factor multiplier }