返回列表 發帖
  1. #include<iostream>
  2. #include<cstdlib>
  3. using namespace std;
  4. int main()
  5. {
  6.    int speed=500;
  7.    re:
  8.    for(int i=1; i<=15; i++)
  9.    {
  10.        if(i==1)
  11.            cout<<"歡   "<<endl;
  12.        if(i==2)
  13.            cout<<" 迎  "<<endl;
  14.        if(i==3)
  15.            cout<<"  光 "<<endl;
  16.        if(i==4)
  17.            cout<<"   臨"<<endl;
  18.        if(i==5)
  19.            cout<<"歡   "<<endl;
  20.        if(i==6)
  21.            cout<<"歡迎  "<<endl;
  22.        if(i==7)
  23.            cout<<"歡迎光 "<<endl;
  24.        if(i==8)
  25.            cout<<"歡迎光臨"<<endl;
  26.        if(i==9)
  27.            cout<<"    "<<endl;
  28.        if(i==10)
  29.            cout<<"歡迎光臨"<<endl;
  30.        if(i==11)
  31.            cout<<"    "<<endl;
  32.        if(i==12)
  33.            cout<<"歡迎光臨"<<endl;
  34.        if(i==13)
  35.            cout<<"    "<<endl;
  36.        if(i==14)
  37.            cout<<"歡迎光臨"<<endl;
  38.        if(i==15)
  39.            cout<<"    "<<endl;
  40.        _sleep(speed);
  41.        system("cls");
  42.    }
  43.    goto re;
  44.    system("pause");   
  45.    return 0;
  46. }
複製代碼

TOP

返回列表