//以下代码为何提示重复定义了成员方法,希望大神能给予解答
#include
#include
#include
#include
#include
//#include "myClass.h"
using namespace std;
void eraseStr11(const char & c,string & s)
{
if(!isalpha(int(c)))
s.erase(c);
}
int main()
{
string str;
getline(cin, str);
string strTmp(str);
for_each( str.begin(), str.end(), bind2nd(ptr_fun(eraseStr11), str)); cout << strTmp; system("pause"); return 0;
}
相关分类