我试图解决这段代码中的错误:
import time
while1 = True
def grader (z):
if z >= 0 or z <= 59:
return "F"
elif z >= 60 or z <= 62:
return "D-"
elif z >= 62 or z <= 66:
return "D"
elif z >= 67 or z <= 69:
return "D+"
elif z >= 70 or z <= 62:
return "C-"
elif z >= 73 or z <= 76:
return "C"
elif z >= 77 or z <= 79:
return "C+"
elif …Run Code Online (Sandbox Code Playgroud) 好吧,初学者,放轻松.谢谢.
#include <iostream>
#include <windows.h>
using namespace std;
int main()
{
int x = 0;
bool while1 = true;
while (while1)
{
cout << x << "\n";
sleep(200);
if (x < 10)
{
while1 = true;
}
else if (x >= 10)
{
while1 = false;
}
x = x+1;
}
cin.get();
}
Run Code Online (Sandbox Code Playgroud)
好吧,所以我不明白为什么程序甚至得到x到10如果我有if语句检查x <10之前我有1添加到x ...请解释.