怎么不行啊?
竟然说
17 C:\Documents and Settings\Administrator\桌面\新建文件夹\11\Dev-Cpp\main.cpp a function-definition is not allowed here before '{' token
晕了
#include <cstdlib>
#include <iostream>
using namespace std;
class A
{
public:
string FunA(string s);
string FunC(string s);
};
int main(int argc, char *argv[])
{
string A::FunA(string s)
{
string sTemp;
sTemp = FunC(s);
cout << "sTemp : " << sTemp << endl;
return sTemp;
}
string A::FunC(string s)
{
return s;
}
system("PAUSE");
return EXIT_SUCCESS;
}