我正在尝试这样做:
#include <iostream>
using namespace std;
class smth {
public:
void function1 () { cout<<"before main";}
void function2 () { cout<<"after main";}
};
call function1();
int main ()
{
cout<<" in main";
return 0;
}
call funtion2();
Run Code Online (Sandbox Code Playgroud)
我希望有这样的信息:"在主要之前""主要""主要之后"
我该怎么做?
c++ ×1