fork(3) download
  1. #include <algorithm>
  2. #include <cctype>
  3. #include <iostream>
  4. #include <string>
  5.  
  6. int main()
  7. {
  8. std::string dmr = "UNIX is basically a simple operating system, but you have to be a genius to understand the simplicity.";
  9. auto last = std::remove_if(dmr.begin(), dmr.end(), ispunct);
  10. dmr.erase(last, dmr.end());
  11. std::cout << dmr << std::endl;
  12. }
Success #stdin #stdout 0s 3428KB
stdin
Standard input is empty
stdout
UNIX is basically a simple operating system but you have to be a genius to understand the simplicity