返回列表 發帖
  1. #include<iostream>
  2. using namespace std;
  3. int main()
  4. {
  5.    int score, level;
  6.    
  7.    cout<<"請輸入您的分數: "<<endl;
  8.    cin>>score;
  9.    level=score/10;
  10.    switch(level)
  11.    {
  12.     case10:
  13.         cout<<"A++,繼續保持!!!"<<endl;
  14.         break;               
  15.     case9:
  16.         cout<<"A,目標A++ !"<<endl;
  17.         break;            
  18.     case8:
  19.         cout<<"B 別掉下去了!孩子!"<<endl;
  20.         break;            
  21.     case7:
  22.         cout<<"c 你肯定在混"<<endl;
  23.         break;            
  24.     case6:
  25.         cout<<"D  竹筍炒肉絲的味道應該不錯要不要來一盤?!"<<endl;
  26.         break;
  27.     default:
  28.         cout<<"F  來人阿!關進地牢,三天後問審!!!!!!!"<<endl;      
  29.     }
  30.    
  31.    system("pause");
  32.    return 0;     
  33. }
複製代碼

TOP

返回列表