返回列表 發帖
  1. #include<iostream>
  2. #include<cstdlib>
  3. using namespace std;
  4. int main()
  5. {
  6.     re:   
  7.    
  8.     int tmp;
  9.      
  10.     for(int i=1;i<=260;i++)
  11.     {
  12.        tmp = i;
  13.       
  14.        if(tmp>=1 && tmp<=20)
  15.        cout<<"謝"<<endl;
  16.       
  17.        if(tmp>=21 && tmp<=40)
  18.        cout<<"  謝"<<endl;
  19.       
  20.        if(tmp>=41 && tmp<=60)
  21.        cout<<"    光"<<endl;
  22.       
  23.        if(tmp>=61 && tmp<=80)
  24.        cout<<"      臨"<<endl;
  25.       
  26.        if(tmp>=81 && tmp<=100)
  27.        cout<<"謝"<<endl;
  28.    
  29.        if(tmp>=101 && tmp<=120)
  30.        cout<<"謝謝"<<endl;
  31.       
  32.        if(tmp>=121 && tmp<=140)
  33.        cout<<"謝謝光"<<endl;
  34.       
  35.        if(tmp>=141 && tmp<=160)
  36.        cout<<"謝謝光臨"<<endl;
  37.       
  38.        if(tmp>=161 && tmp<=180)
  39.        cout<<"  "<<endl;
  40.       
  41.        if(tmp>=181 && tmp<=200)
  42.        cout<<"謝謝光臨"<<endl;
  43.       
  44.        if(tmp>=201 && tmp<=220)
  45.        cout<<"  "<<endl;
  46.       
  47.        if(tmp>=221 && tmp<=240)
  48.        cout<<"謝謝光臨"<<endl;
  49.       
  50.        if(tmp>=241 && tmp<=260)
  51.        cout<<"   "<<endl;

  52.        system("cls");               
  53.     }
  54.       goto re;
  55.       

  56.     system("pause");
  57.     return 0;
  58. }
複製代碼

TOP

返回列表