RosettaCodeData/Task/Associative-array-Iteration/NewLISP/associative-array-iteration-1.l

13 lines
235 B
Text
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
;; using an association list:
(setq alist '(("A" "a") ("B" "b") ("C" "c")))
;; list keys
(map first alist)
;; list values
(map last alist)
;; loop over the assocation list:
(dolist (elem alist)
2024-10-16 18:07:41 -07:00
(println (format "%s -> %s" elem)))