flat map

use flat-map to find odd sum pairs
permutations using flat map
solve exercise 40
solve exercise 2.41

flat-map usage in find triples whose sum is equal to a number.