Haskell is a programming language created in 1990 by Paul Hudak and John Hughes.
#30on PLDB | 33Years Old | 127kRepos |
Haskell is a standardized, general-purpose purely functional programming language, with non-strict semantics and strong static typing. It is named after logician Haskell Curry. The latest standard of Haskell is Haskell 2010. Read more on Wikipedia...
module Example where
sumOverArray :: [Int] -> Int
sumOverArray (x:xs) = x + sumOverArray xs
sumOverArray [] = 0
module Main where
main :: IO ()
main = putStrLn "Hello, world!"
module Main where
main = putStrLn "Hello World"
-- Hello World in Haskell
main = putStrLn "Hello World"
import Data.Char
main :: IO ()
main = do
let hello = "hello world"
putStrLn $ map toUpper hello
$ ghci
Prelude> import Data.Int
Prelude Data.Int> fromIntegral (32767 :: Int16) :: Int8
-1
Prelude Data.Int> fromInteger (2^64 :: Integer) :: Int32
0
! ' '' - -< -<< -> :: ; <- , = => > ? # \* @ [|, |] \ \_ ` {, } {-, -} | ~ as case of class data family instance default deriving do forall foreign hiding if then else import infix infixl infixr let in mdo module newtype proc qualified rec type where