标签:names NPU put sch input ios pre iostream system
#include<iostream> using namespace std; #include<string> int main() { int score = 0; cout << "Input your score,please :" << endl; cin >> score; cout << "Your score is " << score << endl; if (score >= 512) { cout << "You will own a good school!" << endl; } system("pause"); return 0; }
#include<iostream> using namespace std; #include<string> int main() { int score = 0; cout << "Input your score,please :" << endl; cin >> score; cout << "Your score is " << score << endl; if (score >= 512) cout << "You will own a good school!" << endl; else cout << "see you next year" << endl; system("pause"); return 0; }
#include<iostream> using namespace std; #include<string> int main() { float score = 0; cout << "Input students‘ score(0 to 100),please :" << endl; cin >> score; cout << "score is " << score << endl; if (score >= 90) cout << "The student‘ score is A" << endl; else if(score>=80) cout << "The student‘ score is B" << endl; else if (score >= 60) cout << "The student‘ score is C" << endl; else cout << "The student‘ score is D" << endl; system("pause"); return 0; }
标签:names NPU put sch input ios pre iostream system
原文地址:https://www.cnblogs.com/hackerteen/p/12375121.html