Compile a script using ghc <file name>. This generates a binary whose name does not have the .hs extension.
A script must contain a main function to compile.

Run a script directly using runghc <file name>.


Type in ghci to use the interactive REPL.
Interactive scripts do not require a main function.
Type in :l <script name without extention> to load a script (Technically a ‘module’).
Type in :r to reload all loaded modules.