added the ability to read a file
better pretty printing