#pragma region ourfunc.cpp
//ourfunc.cpp -- defining your own function
#if 1
#include <iostream>
void simon(int); //function prototype for simon()
int main()
{
using namespace std;
simon(3); //call the simon()function
cout << "Pick an integer: ";
int count;
cin >> count;
simon(count);//call it again
cout << "Done!" << endl;
return 0;
}
C++ Primer Plus--0a4用户自定义的函数
最新推荐文章于 2024-09-17 00:14:16 发布