Back to notes -- Keyboard shortcut: 'u'  previous -- Keyboard shortcut: 'p'        Slide program -- Keyboard shortcut: 't'    A simple demo processing of the document.Lecture 6 - slide 7 : 22
Program 2
(define (process-document! doc)
  (file-write (transform-document doc) "res.lsp"))

(define (transform-document doc)
  (let ((top-level-forms (document-forms doc)))
   (map
     (lambda (subform) 
       (subform-keyword subform))
     top-level-forms)))


(define document-forms cdr)
(define subform-keyword car)