Functional programming cources material (scala code)