#include <iostream>
#include <string>
using namespace std;
int main(int argc, char* argv[]) {
string str = "";
cin >> str;
remove(str.begin(), str.end(), ' ');
cout << str;
cin.ignore();
}
오류는 " '제거'기능은 (C2660)를 3 개 인수를 고려하지 않습니다"라고
대신 [this] (http://msdn.microsoft.com/en-us/library/2da4hk1d%28v=VS.100%29.aspx) 함수를 호출해야합니다. – Jon
+1 완전한 예제 프로그램을 제공합니다. http://sscce.org –
@Jon : 좋은 캐치. 그래서 모든 방식의 기능을 숨기기 때문에'using namespace std'를 사용하지 않는 것을 선호합니다. – Johnsyweb