adding functional programming