* Lecture 1A
https://youtu.be/-J_xL4IGhJA

Welcome to "Computer" "Science"
It's not a science
It's not about computers

*Process*, how to do things
 - developing a way to talk about "how to" knowledge
 - vs declarative knowledge, what things are
*Procedures*

Techniques for Controlling Complexity:
 - Black-Box Abstraction
 - Conventional Interfaces
 - Metalinguistic Abstraction

"procedures that talk about other procedures"

-----------

Essence of a computer language:
  Primitive Elements
  Means of Combination
  Means of Abstraction


     ,- operator    ,- operand
   ( +   3   17.4   5) --> 25.4
   `------------------' 
       combination

"prefix notation"
"pretty printing"
"syntactic sucar"

(define (square x) (* x x)) is sugar for
(define square (lambda (x) (* x x)))


!! no distinction in lisp between arbitrary things and things built in

#+BEGIN_SRC scheme
  (define (try guess x)
    (if (good-enough? guess x)
	guess
	(try (improve guess x) x)))
  (define (sqrt x) (try 1 x))
  (define (improve guess x)
    (average guess (/ x guess)))
  (define (good-enough? guess x)
    (< (abs (- (square guess) x))
       .001))
#+END_SRC

(sqrt 2)
(try 1 2)
(try (improve 1 2) 2)
     `------------'
      avg 1 (/ 2 1)
(try 1.5 2)
(try (average 1.5 (/ 2 1.5)) 2)
(try 1.3333 2)


BLOCK STRUCTURE

to write lisp is to express imperitive knowledge

|             | procedures      | data     |
|-------------+-----------------+----------|
| primitive   | +  /  >  =      | 12 143.7 |
| elements    | - <             |   7      |
|-------------+-----------------+----------|
| means of    | ( ) composition |          |
| combination |   cond  if      |          |
|-------------+-----------------+----------|
| means of    |  define         |          |
| abstraction |                 |          |
|-------------+-----------------+----------|

