Hello,
Sure can. Actually a good programming procedure. main() is a function, just like factorial(), or maybe openfile() or fillarray(). The thing that makes main special is that it is "called" first.
What you want to do is just fine. Local variables are the way to go!
Christian
Reputation Points: 121
Solved Threads: 57
Posting Virtuoso
Offline 1,629 posts
since Mar 2004