Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- QT
- Book
- Software Engineering
- history
- erlang
- Book review
- France
- web
- comic agile
- Kuala Lumpur
- Linux
- hbase
- MySQL
- essay
- psychology
- Python
- Spain
- RFID
- django
- program
- Malaysia
- agile
- Java
- Italy
- management
- Programming
- ubuntu
- hadoop
- leadership
- programming_book
Archives
- Today
- Total
main = putStrLn "Hello, World" 본문
http://haskell.springnote.com
1. install(Ubuntu, http://ubuntuprogramming.wikidot.com/haskell)
$ sudo apt-get install ghc6
2. compile mode
$ vi hello.hs
main = putStrLn "Hello, World"
$ ghc --make hello
[1 of 1] Compiling Main ( hello.hs, hello.o )
Linking hello ...
$ ./hello
Hello, World
$
3. interpreter mode
$ ghci
GHCi, version 6.8.2: http://www.haskell.org/ghc/ :? for help
Loading package base ... linking ... done.
Prelude> let fact x = product[1..x]
Prelude> fact 5
120
Prelude> :q
Leaving GHCi.
$
1. install(Ubuntu, http://ubuntuprogramming.wikidot.com/haskell)
$ sudo apt-get install ghc6
2. compile mode
$ vi hello.hs
main = putStrLn "Hello, World"
$ ghc --make hello
[1 of 1] Compiling Main ( hello.hs, hello.o )
Linking hello ...
$ ./hello
Hello, World
$
3. interpreter mode
$ ghci
GHCi, version 6.8.2: http://www.haskell.org/ghc/ :? for help
Loading package base ... linking ... done.
Prelude> let fact x = product[1..x]
Prelude> fact 5
120
Prelude> :q
Leaving GHCi.
$
Comments