let map_to_all = function f -> (let rec g = function lx -> if is_empty_list (lx) then empty_list () else cons_list (f (head (lx)), g (tail (lx))) in g)