返回列表 發帖
  1. #include<iostream>
  2. #include<cstdlib>
  3. #include<ctime>
  4. using namespace std;

  5. void welcome()
  6. {
  7. cout<<"歡迎光臨"<<endl;
  8. }
  9.             

  10. int main()
  11. {
  12. int x;
  13.    cout<<"請輸入次數:";
  14.    cin>>x;
  15.    for(int i=0;i<x;i++)
  16.    welcome();
  17. system("pause");
  18.     return 0;
  19. }
複製代碼

TOP

返回列表