#include <iostream>
#include <algorithm>
#include <cstring>

using namespace std;

void removeCharsFromString( string &str, char* charsToRemove ) {
   for ( unsigned int i = 0; i < strlen(charsToRemove); ++i ) {
      str.erase( remove(str.begin(), str.end(), charsToRemove[i]), str.end() );
   }
}

int main() {
	//example of usage:
	string str = "(My)String -before";
	cout << str << endl; //before
	removeCharsFromString( str, "()-" );
	cout << str << endl; //after
	return 0;
}