fork download
  1. import System.Environment
  2.  
  3. main = do
  4. filenames <- getArgs
  5. stdin <- getContents
  6. putStr stdin
  7. writeFile (getFilename filenames) stdin
  8. where
  9. getFilename :: [String] -> String
  10. getFilename [] = "stdout.txt"
  11. getFilename (fn:_) = fn
  12.  
Not running #stdin #stdout 0s 0KB
stdin
Standard input is empty
stdout
Standard output is empty