simple definition of flatten
flatmap
flatten in terms of flat map
verbose definition