fork(1) download
  1. #include <iostream>
  2. #include <string>
  3.  
  4. using namespace std;
  5.  
  6. int main()
  7. {
  8. string s = "There are \\{$count} types of things.";
  9. cout << s << endl;
  10.  
  11. size_t slash_pos = s.find("\\");
  12.  
  13. if(slash_pos != string::npos)
  14. s.erase(slash_pos, 1);
  15.  
  16. cout << s << endl;
  17.  
  18. return 0;
  19. }
Success #stdin #stdout 0s 3228KB
stdin
Standard input is empty
stdout
There are \{$count} types of things.
There are {$count} types of things.