How to print a list of lists

I’m trying to print a specific list, but it doesn’t work let rec listes_paires l = match l with | [] -> [] | x :: r -> if List.length x mod 2 = 0 then (x :: (listes_paires r)) else ((x@x):: (listes_paires r));; List.iter print_int (listes_paires [[]; [1];[1;2];[1;2;3];[];[5;4;3;2;1]]);; Error message says : Line 5,… Read More How to print a list of lists