Your SlideShare is downloading. ×
0
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Learning Lisp
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Learning Lisp

804

Published on

Video of presentation available on youtube: …

Video of presentation available on youtube:
http://www.youtube.com/watch?v=y9RekASi2MI

Published in: Technology, Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
804
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
2
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • \n
  • \n
  • \n
  • \n
  • \n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • Cambridge polish notation\n
  • \n
  • \n
  • \n
  • \n
  • \n
  • Parens are actually literals for lists.\nData and code has the same representation.\n
  • Parens are actually literals for lists.\nData and code has the same representation.\n
  • Compile time metaprogrammering - ingen performance overhead\nMan bruker vanlige funksjoner til å manipulere kode, på samme måte som data\n\n\n\n
  • Compile time metaprogrammering - ingen performance overhead\nMan bruker vanlige funksjoner til å manipulere kode, på samme måte som data\n\n\n\n
  • Compile time metaprogrammering - ingen performance overhead\nMan bruker vanlige funksjoner til å manipulere kode, på samme måte som data\n\n\n\n
  • \n
  • \n
  • \n
  • Transcript

    • 1. Learning Lisp Alf Kristian Støyle
    • 2. sum(1, 2);
    • 3. sum(1, 2)
    • 4. (sum 1, 2)
    • 5. (sum 1 2)
    • 6. (sum 1 2)
    • 7. (sum 1 2)
    • 8. Prefix notationFunction name Parameters (sum 1 2)
    • 9. (sum 1 2)
    • 10. (sum)(sum 1 2)(sum 1 2 3)
    • 11. (sum);=> 0(sum 1 2);=> 3(sum 1 2 3);=> 6
    • 12. (+);=> 0(+ 1 2);=> 3(+ 1 2 3);=> 6
    • 13. (+);=> 0(+ 1 2) 1 + 2;=> 3(+ 1 2 3) 1 + 2 + 3;=> 6
    • 14. Lists(3 2 1);=> (3 2 1)(+ 3 2 1);=> 6
    • 15. Lists(3 2 1);=> (3 2 1)(+ 3 2 1);=> 6(defn iterate [f x] (cons x (lazy-seq (iterate f (f x)))))
    • 16. Lists(3 2 1);=> (3 2 1)(+ 3 2 1);=> 6(defn iterate [f x] (cons x (lazy-seq (iterate f (f x)))))
    • 17. Macros(1 + 2)
    • 18. Macros(infix (1 + 2));=> 3
    • 19. Macros(infix (1 + 2));=> 3(defmacro infix [form] `(~(second form) ~(first form) ~@(nnext form)))
    • 20. Macros(infix (1 + 2));=> 3(defmacro infix [form] `(~(second form) ~(first form) ~@(nnext form)))(macroexpand (infix (1 + 2)));=> (+ 1 2)
    • 21. (defn iterate [f x] (cons x (lazy-seq (iterate f (f x)))))
    • 22. Abstract syntax tree(defn iterate [f x] (cons x (lazy-seq (iterate f (f x)))))
    • 23. Clojure

    ×