fork download
  1. #include <iostream>
  2. #include <string>
  3. #include <thread>
  4. #include <chrono>
  5.  
  6. int main()
  7. {
  8. std::string message = "Hello, world!";
  9. for(auto c : message)
  10. {
  11. std::cout << c;
  12. std::this_thread::sleep_for(std::chrono::milliseconds{100});
  13. }
  14. std::cout << std::endl;
  15. }
  16.  
Success #stdin #stdout 0s 3272KB
stdin
Standard input is empty
stdout
Hello, world!