[Tutor] My horrible looking program needs improvement.

Alan Gauld alan.gauld at btinternet.com
Mon Nov 24 19:25:56 CET 2008

> Everything is in main(), I would like to use functions but ran into
> problems with the scope of my variables.

Did your functions have parameters?
Thats usually how to deal with passing names between scopes.

> Is this the place where somebody could go over my program


> If this is the place, how do I show the program, in-line or 
> attached?

If its short (<100 lines?) just paste it into a mail - try to preserve
formatting please! Otherwise posting it on a web site like
pastebin is a good option - provides good formatting and colouring...


Alan Gauld
Author of the Learn to Program web site

More information about the Tutor mailing list