Here is how you can run this:

```
ikarus test.scm
```

Then the correct stuff should be imported and you can type:

```
> (run 1 (q) (exist (x) (proveo q '() '() '() x)))
((and (lit (pos (sym *0))) (lit (neg (sym *0)))))
```

What is below is irrelevant for 2009.

`let`

s rewritten as `lets`

and all the
`let*`

rewritten as `let*s`

. This causes all
the occurrences of `let`

and `let*`

to disappear.
This removes all the lexical context that stores positions. The
only changes occurred in `OBJECT`

and `def-class`

.
Assignment for April 11th class.

Here is r* a lambda-calculus reducer.

(define r* (lambda (e) (let ((t (r0 e (lambda (hole) hole)))) (cond ((equal? t e) t) (else (r* t))))))

(define r0 (lambda (e ctx) (match e (,x (guard (symbol? x)) (ctx x)) ((lambda (,id) ,body) (r0 body (lambda (hole) (ctx `(lambda (,id) ,hole))))) ;;; in Scheme we don't go under the lambda, but here we do ;;; just for the fun of it. ((,rator ,rand) (match rator (,f (guard (symbol? f)) (r0 rand (lambda (hole) (ctx `(,f ,hole))))) ((lambda (,id) ,body) (ctx (beta-subst rand id body))) (,else (r0 rator (lambda (hole) (ctx `(,hole ,rand)))))))) ;;; We have chosen to evaluate the rator first. ;;; obviously this is arbitrary.Grab your body[id <- rand] from last semester's handout to implement

(beta-subst rand id body)Finish implementing this reducer by defining beta-subst (see Stoy) and then try to mini-kanrenize it. ... Dan