![Forrest logo](/images/logo.png)
ghc:tldr:ef70b
The command "ghci" stands for "GHCi" which stands for "Glasgow Haskell Compiler interactive". It is an interactive command line interface for executing Haskell code.
When you run the "ghci" command in your terminal, it starts the GHCi environment, which provides an interactive environment for Haskell development. It allows you to load Haskell files, define and test functions, and evaluate Haskell expressions.
Once you run the "ghci" command, you will see a prompt that looks like "Prelude>". This is the GHCi prompt, where you can type in Haskell code and see the results immediately.
For example, you can define a function like:
Prelude> let square x = x * x
You will see that GHCi accepts the function definition and assigns it to the name "square". You can then use the function by calling it with the desired arguments:
Prelude> square 5
25
GHCi also provides other features like type inference, tab completion, and the ability to load external Haskell modules. It is a powerful tool for exploring and experimenting with Haskell code.