# This program corrects program 1. Note that the n in square() and # the n in main() are different variables. When square() is called, # the value of main()'s n is assigned to the value of square()'s n, # but the fact that they have the same name is just a coincidence. # Either could be changed to x, or to anything else, and the program # would still work. def square(n): n = n * n return n def main(): n = 3 print n, "squared is", square(n) main()