python sb 问题
时间:2014-06-28 12:47:52
收藏:0
阅读:294
PROGRAM_MAX_LENGTH = 60*60*3 #3 hours
skiptimes = 0
TOTALTIMES = 0
def xxx():
print TOTALTIMES #fine consider it as constant
#TOTALTIMES += 1 #NOT OK
global TOTALTIMES
TOTALTIMES += 1 #OK
评论(0)