Hello,
I am creating a hash table like this:
(defparameter *hash1* (make-hash-table))
(setf (gethash 'paris *hash1*) 'france)
(setf (gethash 'lyon *hash1*) 'france)
(setf (gethash 'nantes *hash1*) 'france)
(setf (gethash 'berlin *hash1*) 'allemagne)
(setf (gethash 'cologne *hash1*) 'allemagne)
(setf (gethash 'berne *hash1*) 'suisse)
(setf (gethash 'genève *hash1*) 'suisse)
(setf (gethash 'rome *hash1*) 'italie)
I would like to know if it is possible to create such hash table like in
perl:
%hash1 = qw(paris france lyons france ......);
i.e.
is it possible to use one time (setf (gethash)) to initialize the hash
table or does exist a function lisp to do that ?
tia.
--
Gérard
|