Hello world

home1 home2
 Bib
 Algorithms
 Bioinfo
 FP
 Logic
 MML
 Prog.Lang
and the
 Book

FP
 Haskell
  Haskell98
File hello.hs
main = putStr "Hello world.\n"

-- Haskell98 Hello world program

NB.
putStr :: String -> IO ()
putStrLn :: String -> IO ()
putChar :: Char -> IO ()
File hello02.hs
main = putStr "Hello " >> putStr "World" >> putStrLn "."

-- Another Hello world

NB. The operator >> combines two (or more) IO actions

7/2002.
Coding Ockham's Razor, L. Allison, Springer

A Practical Introduction to Denotational Semantics, L. Allison, CUP

Linux
 Ubuntu
free op. sys.
OpenOffice
free office suite
The GIMP
~ free photoshop
Firefox
web browser

Haskell:
(:) cons
[x1,...] list
[ ]list
(++) append
\ λ :-)
:: has type
Compared

© L. Allison   http://www.allisons.org/ll/   (or as otherwise indicated),
Faculty of Information Technology (Clayton), Monash University, Australia 3800 (6/'05 was School of Computer Science and Software Engineering, Fac. Info. Tech., Monash University,
was Department of Computer Science, Fac. Comp. & Info. Tech., '89 was Department of Computer Science, Fac. Sci., '68-'71 was Department of Information Science, Fac. Sci.)
Created with "vi (Linux + Solaris)",  charset=iso-8859-1,  fetched Wednesday, 17-Apr-2024 08:22:10 AEST.