better error messages; remove dead code
more classic printing of lists and arrays (ocaml-style)