This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
####################################### | |
# | |
# asciiplay.py | |
# Algot Runeman | |
# November 11, 2012 | |
# June 30, 2013 (reversed order of list) | |
# | |
####################################### | |
a = 'Jones' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
######################################## | |
# | |
# rps.py - 1.7 Rock Paper Scissors Mechanical MOOC | |
# Algot Runeman | |
# 2012-11-30 | |
# | |
######################################## | |
##RPS MMOOC 1.7 Truth Table | |
##========================= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Two function Samples | |
# First version doesn't export the calculation out of the function | |
# even though the function itself works just fine. | |
area = 0 # initialize the global variable | |
def area_rectangle(length,width): | |
area = length * width | |
print "inside function",area # area is evaluated inside the function 35 in my example |