Q:对输入的成绩进行登记划分。
#include<iostream> #include<cstdio> using namespace std; int main() { int score; cin>>score; if(score<80) { if(score<70) { if(score<60) cout<<"E"<<endl; else cout<<"D"<<endl; } cout<<"C"<<endl; } else { if(score>=90) cout<<"A"<<endl; else cout<<"B"<<endl; } return 0; }