第1个回答 2014-03-10
def main():
for num in range (1, 124):
if not num%3 and not num%5:
print "C"
elif not num%3:
print "A"
elif not num%5:
print "B"
else:
print(num)
第2个回答 2014-03-10
高清count_digits(S):
回报LEN([我为我在s中,如果i.isdigit()])
高清count_digits2(S):
返回地图(str.isdigit,S) 。算(真)
S ='a1b2c345'
打印count_digits(次)
打印count_digits2(S)
第3个回答 2014-03-10
def main():
for num in range(1,124):
if num%3 == 0 and num%5 == 0:
print 'C'
elif num%3 == 0:
print 'A'
elif num%5 == 0:
print 'B'
else:
print num
if __name__ == "__main__":
main()本回答被提问者采纳