in reply to Changing the format of output

my actual code:

Every one of those line numbers is a syntax error