I am beginning to learn lisp and I thought I would document the whole process of learning in a blog. The environment that I plan to learn to learn lisp is the following. There is no particular reason for choosing any of these tools.
- Ubuntu 14 - quite comfortable with the OS.
- SBCL (Steel Bank Common Lisp) - Goal is to learn this.
- Emacs - Have never used it before. I am a Vim fan.
- Slime - An IDE to make things easier.
Installation steps:
- C-M-t to open terminal
sudo apt-get install emacs24
sudo apt-get install sbcl
sudo apt-get install slime
curl -O http://beta.quicklisp.org/quicklisp.lisp - quicklisp installation steps here.
- Run emacs
- C-x C-f test.lisp
- C-x 3
- M-x slime
- In slime window type
- (+ 1 2)↵
- Check that result is 3
- In other window type
(defun test(x y)
(+ x y)) - C-c C-c
- Slime window
- (test 3 4)↵
- Check that output is 7.
No comments:
Post a Comment