返回列表 發帖
#include<iostream>
#include<cstdlib>
using namespace std;
int main(){
    re:
        int x;
    cout<<"請輸入你的成績";
    cin>>x;
    if(x==100)
    cout<<"哇!滿分"<<endl;
    else if(x<100&&x>60)
        cout<<"恭喜及格"<<endl;
    else if(x<60&&x>0)
        cout<<"不及格?斬!"<<endl;
    else if(x==0)
        cout<<"零分?斬!"<<endl;
    else
        cout<<"輸入錯誤"<<endl;

    goto re;
system("pause");
return 0;

TOP

返回列表