#include <iostream>
using namespace std;
// 编写一个C++程序,它使用3个用户定义的函数(包括main()函数,并生成下面的输出:
//Three blind mice
//Three blind mice
//See how they run
//See how they run
void mice();//声明要调用的函数原型
void run();
int main(){
mice();
mice();//调用mice()函数 ,输出 Three blind mice
run();
run();//调用run()函数 ,输出See how they run
return 0;
}
void mice(){
cout<<"Three blind mice"<<endl;
}
void run(){
cout<<"See how they run"<<endl;
}
C++Primer Plus (第6版)中文版 第2章 2.7 编程练习 第3题
最新推荐文章于 2023-02-27 11:29:12 发布