69 lines
3.0 KiB
Org Mode
69 lines
3.0 KiB
Org Mode
|
#+TITLE: Zapiski #1 srečanja programerskega bralnega krožka SICP
|
||
|
#+AUTHOR: Jurij
|
||
|
#+OPTIONS: toc:nil num:nil author
|
||
|
|
||
|
* Zanimivi izseki
|
||
|
** str. 9
|
||
|
#+BEGIN_QUOTE
|
||
|
Every reader should ask himself periodically "Toward what end, toward what end?" — but do not ask it too often lest you pass up the fun of programming for the constipation of bittersweet philosophy.
|
||
|
#+END_QUOTE
|
||
|
|
||
|
#+begin_quote
|
||
|
Lisp is a survivor, having been in use for about a quarter of a century.
|
||
|
#+end_quote
|
||
|
** str. 11
|
||
|
#+begin_quote
|
||
|
It is better to have 100 functions operate on one data structure than to have 10 functions operate on 10 data structures.
|
||
|
#+end_quote
|
||
|
** str. 18
|
||
|
#+begin_quote
|
||
|
Thus, programs must be written for people to read, and only incidentally for machines to execute.
|
||
|
#+end_quote
|
||
|
** str. 19
|
||
|
#+begin_quote
|
||
|
Underlying our approach to this subject is our conviction that "computer science" is not a science and that its significance has little to do with computers.
|
||
|
#+end_quote
|
||
|
** str. 27
|
||
|
#+begin_quote
|
||
|
Finally, we would like to acknowledge the support of the organizations that have encouraged this work over the years, including support from Hewlett-Packard, made possible by Ira Goldstein and Joel Birnbaum, and support from DARPA, made possible by Bob Kahn.
|
||
|
#+end_quote
|
||
|
|
||
|
Bob Kahn je mdr. soavtor protokolov TCP in IP, pionir omreževanja. V DARPA postal kasneje direktor IPTO (Informational Processing Techniques Office), kjer je ustanovil milijardo-dolarski projekt Strategic Copmuting Initiative, največjo investicijo ameriške federalne vlade v računalništvo ever ('83 do '93) - razvijali so proizvodnjo čipov in umetne inteligence. Ustrašili so se japoncev, podobno kot v 50ih sovjetov.
|
||
|
|
||
|
Po DARPA ustanovil CNRI (corporation for national research initiatives), neprofitno organizacijo kjer je delal tudi guido van rossum (avtor pythona). Tam so izdali python verzije 1.3 do 1.6 ter GNU mailman.
|
||
|
|
||
|
Preko očeta v sorodu s fizikom Hermanom Kahnom, ki je napisal knjigo o tem kako bi amerika lahko zmagala nuklearno vojno in postal inspiracija za dr. Strangelove-a v znanem Kubrickovem filmu. Ustanovil je Hudson institut, konzervativni think tank ki je začel pri premišljevanju hladnovojnih scenarijev in se razširil na polja ekonomije, zdravstva, šolstva in gemblanja. Delal je tudi v RAND korporaciji, močnem hladnovojnem inštitutu, vpletenem v vietnamsko vojno, iraško vojno, danes pa kuri "AI apokaliptični" scenarij.
|
||
|
|
||
|
** str. 77
|
||
|
Stoy 1977
|
||
|
* Vaje
|
||
|
** 1.1 Kaj vrnejo izrazi?
|
||
|
** 1.2 Pretvori izraz v prefix obliko
|
||
|
#+begin_src scheme :exports both
|
||
|
(/ (+ 5 4
|
||
|
(- 2
|
||
|
(- 3
|
||
|
(+ 6
|
||
|
1/3))))
|
||
|
(* 3
|
||
|
(- 6 2)
|
||
|
(- 2 7)))
|
||
|
#+end_src
|
||
|
|
||
|
#+RESULTS:
|
||
|
: -43/180
|
||
|
** 1.3 procedura, ki prejme 3 argumente in vrne vsoto kvadratov vecjih dveh
|
||
|
|
||
|
#+begin_src scheme :exports both
|
||
|
(define (vsota-vecjih-kvadratov a b c)
|
||
|
(cond ((<= a b c) (+ (* b b) (* c c)))
|
||
|
((<= b a c) (+ (* a a) (* c c)))
|
||
|
(else (+ (* b b) (* a a)))))
|
||
|
|
||
|
(vsota-vecjih-kvadratov 6 1 7)
|
||
|
#+end_src
|
||
|
|
||
|
#+RESULTS:
|
||
|
: 85
|
||
|
** 1.4
|