snoyberg / mono-traversable

Type classes for mapping, folding, and traversing monomorphic containers
155 stars 67 forks source link

Getting problems in the basic program of Haskell #Haskell #220

Closed AkshatSigma closed 7 months ago

AkshatSigma commented 7 months ago

I wrote this code in a file name example.hs main = putStrLn "Hello, world" now it's showing this error akshatkumarsharma@Akshats-Air Haskellproject % ghc example.hs [1 of 2] Compiling Main ( example.hs, example.o )

example.hs:1:1: error: The IO action ‘main’ is not defined in module ‘Main’ what should I do to solve this, please help and tell as explained as possible, I am a beginner and don't know anything. Have i installed Haskell wrongly?

Screenshot 2024-04-01 at 19 44 50
BebeSparkelSparkel commented 7 months ago

Please read https://www.haskell.org/get-started/ and look up specifics of VS Code and GHC Haskell. The issues here are for this repository and specifically for the packages

Your problem/question is not specific to these packages. If you still have problems after reading the getting started page linked above, post your question on https://discourse.haskell.org/ .