removal of some redundant statements
minor tidy of print statements