python小学堂1
Posted nyqxiaoqiang
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了python小学堂1相关的知识,希望对你有一定的参考价值。
sun=0 start=1 while True: start1=start%2 if start1==1: sun = start + sun elif start1==0: sun=sun-start if start==100: break start += 1 print(sun)
1 sun=0 2 start=1 3 while True: 4 start1=start%2 5 if start1==1: 6 sun = start + sun 7 elif start1==0: 8 sun=sun-start 9 if start==100: 10 break 11 start += 1 12 print(sun)
sun=0 start=1 while True: start1=start%2 if start1==1: sun = start + sun elif start1==0: sun=sun-start if start==100: break start += 1 print(sun)
1 sun=0 2 start=1 3 while True: 4 start1=start%2 5 if start1==1: 6 sun = start + sun 7 elif start1==0: 8 sun=sun-start 9 if start==100: 10 break 11 start += 1 12 print(sun)
以上是关于python小学堂1的主要内容,如果未能解决你的问题,请参考以下文章