这道题有异议
sum = 0
x = 1
while x < 100:
x = x + 2
sum = sum + x
print sum
上下两个代码都能运行通过,哪个才是正确的,懵。质数不是含2吗
sum = 0
x = 0
while x < 100:
x = x + 2
sum = sum + x
print sum
sum = 0
x = 1
while x < 100:
x = x + 2
sum = sum + x
print sum
上下两个代码都能运行通过,哪个才是正确的,懵。质数不是含2吗
sum = 0
x = 0
while x < 100:
x = x + 2
sum = sum + x
print sum
2018-12-16
举报