fork(1) download
  1. #include <iostream>
  2. #include <cstdlib>
  3. #include <string>
  4.  
  5. int main(int ac,char *av[]) {
  6. std::string Command = "rm -f ";
  7.  
  8.  
  9. std::cout << "「このプログラムが起動するのは一度きりである。実行ののち、消去される。」" << std::endl;
  10.  
  11. Command += av[0];
  12.  
  13. std::cout << '>' << Command << std::endl;
  14. ////std::system(Command.data());
  15.  
  16. return 0;
  17.  
  18. }
Success #stdin #stdout 0s 4396KB
stdin
Standard input is empty
stdout
「このプログラムが起動するのは一度きりである。実行ののち、消去される。」
>rm -f ./prog