This is similar to How to print a list in Python “nicely”, but I would like to print the list even more nicely -- without the brackets and apostrophes and commas, and even b
Although not designed for it, the standard-library module cmd has a utility for printing a list of strings in multiple columns
import cmd cli = cmd.Cmd() cli.columnize(foolist, displaywidth=80)
You even then have the option of specifying the output location, with cmd.Cmd(stdout=my_stream)
cmd.Cmd(stdout=my_stream)