Tidy code and add status output when running the program