(define (attach-type type contents)
(cons type contents))
(define (type datum)
(if (not (atom? datum))
(car datum)
(error "Bad typed datum -- TYPE" datum)))
(define (contents datum)
(if (not (atom? datum))
(cdr datum)
(error "Bad typed datum -- CONTENTS" datum)))
となります.