L = [75, 92, 59, 68]
sum = 0.0
for score in L:
sum=sum+score
print sum / 4
sum = 0.0
for score in L:
sum=sum+score
print sum / 4
2015-10-01
score = 55
if score>=60:
print 'passed'
else:
print 'failed'
if score>=60:
print 'passed'
else:
print 'failed'
2015-10-01
for x in range(1,10):
for y in range(1,10):
if x< y:
print str(x)+str(y)
for y in range(1,10):
if x< y:
print str(x)+str(y)
2015-10-01
def firstCharUpper(s):
return s.upper()[:1]+s[1:]
print firstCharUpper('hello')
print firstCharUpper('sunday')
print firstCharUpper('september')
return s.upper()[:1]+s[1:]
print firstCharUpper('hello')
print firstCharUpper('sunday')
print firstCharUpper('september')
2015-09-30
for x in range(11,100):
n = x / 10
m = x % 10
if n < m:
print(x)
n = x / 10
m = x % 10
if n < m:
print(x)
2015-09-30