Language
Haskell
Compiler
ghc 8.4.2
Options
Warnings
$ ghc prog.hs -o prog.exe -Wall
Exit Code:
1
Author
anonymous
over 5 years ago
Haskell
ghc 8.4.2
Author
anonymous
over 5 years ago
$ ghc prog.hs -o prog.exe -Wall
[1 of 1] Compiling Main ( prog.hs, prog.o )
prog.hs:8:14: error:
• Couldn't match expected type ‘Double’ with actual type ‘Int’
• In the second argument of ‘($)’, namely ‘(a / b :: Double)’
In a stmt of a 'do' block: print $ (a / b :: Double)
In the expression:
do let a = ...
b = ...
print $ (a / b :: Double)
|
8 | print $ (a / b :: Double)
| ^^^^^