Play audio slide show -- Keyboard shortcut: 'x'  Back to slide -- Keyboard shortcut: 'u'  previous -- Keyboard shortcut: 'p'        Annotated program -- Keyboard shortcut: 't'      generate-leq-application.scm - An application of generate-leq which sorts the manual clauses.Lecture 4 - slide 34 : 34
Program 2

(define (syntactic-form name)
  (lambda subclauses (cons name subclauses)))

(define form (syntactic-form 'form))
(define title (syntactic-form 'title))
(define description (syntactic-form 'description))
(define parameter (syntactic-form 'parameter))
(define pre-condition (syntactic-form 'pre-condition))
(define misc (syntactic-form 'misc))
(define result (syntactic-form 'result))

(define (manual-page . clauses)
 (let ((clause-leq? 
           '(title form description 
             pre-condition result misc)
  (let ((sorted-clauses (sort-list clauses clause-leq?)))
    (present-clauses sorted-clauses))))