birds - birds = 5000 print 'texas has', birds, 'birds.' #...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
# This program demonstrates two functions that # have local variables with the same name. # def main(): # Call the texas function. texas() # Call the california function. california() # Definition of the texas function. It creates # a local variable named birds. def texas():
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: birds = 5000 print 'texas has', birds, 'birds.' # Definition of the california function. It also # creates a local variable named birds. def california(): birds = 8000 print 'california has', birds, 'birds.' # Call the main function. main()...
View Full Document

This note was uploaded on 07/15/2010 for the course CSE CSE1530 taught by Professor Lew during the Spring '09 term at York University.

Ask a homework question - tutors are online