Computation hPrinthdl t writes the string
representation of t given by the show function to the
file or channel managed by hdl and appends a newline.
This operation may fail with the same errors as hPutStrLn
Examples
>>> hPrint stdout [1,2,3]
[1,2,3]
>>> hPrint stdin [4,5,6]
*** Exception: <stdin>: hPutStr: illegal operation (handle is not open for writing)
Computation hPrinthdl t writes the string
representation of t given by the shows function to the
file or channel managed by hdl and appends a newline.
This operation may fail with: