[racket] structure question

From: Manfred Lotz (manfred.lotz at arcor.de)
Date: Tue Dec 7 23:51:11 EST 2010

Hi there,
In Common Lisp I can define something like this:


(defvar *db* nil)

(defun make-book (&key author title)
  (list :author author :title title))

(defun add-record (book) (push book *db*))

(add-record (make-book :author "John Grisham" :title "The Client"))



I like to use field names like in the example above. Can I do this in
racket?



-- 
Thanks,
Manfred






Posted on the users mailing list.