i = 1
while i <=5:
print (i)
i=i + 1
print ("ok")
Run Code Online (Sandbox Code Playgroud)
所以这不是我的代码,而是关于sololearn的python教程
它应该输出:
1
2
3
4
5
Run Code Online (Sandbox Code Playgroud)
然后停下来
但是当我这样做时,我得到一个1的循环
1
1
1
1
1
Run Code Online (Sandbox Code Playgroud)
我相信这不是核心
所以即时通讯是我在改写过程中犯了错误(我肯定已经纠正过)或者这个代码是错误的代码,它在应用程序中被错误地使用了
或者更改了python版本,所以这不再起作用了
python ×1