From ... Path: supernews.google.com!sn-xit-02!sn-xit-03!supernews.com!xfer13.netnews.com!netnews.com!news.maxwell.syr.edu!npeer.kpnqwest.net!EU.net!Norway.EU.net!127.0.0.1!nobody From: Erik Naggum Newsgroups: comp.lang.lisp Subject: Re: Setting keys/values in alists Date: 30 Oct 2000 14:25:34 +0000 Organization: Naggum Software; vox: +47 800 35477; gsm: +47 93 256 360; fax: +47 93 270 868; http://naggum.no; http://naggum.net Lines: 32 Message-ID: <3181904734006098@naggum.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: oslo-nntp.eunet.no 972918483 14782 195.0.192.66 (30 Oct 2000 15:08:03 GMT) X-Complaints-To: newsmaster@eunet.no NNTP-Posting-Date: 30 Oct 2000 15:08:03 GMT mail-copies-to: never User-Agent: Gnus/5.0803 (Gnus v5.8.3) Emacs/20.7 Xref: supernews.google.com comp.lang.lisp:2899 * Daniel Henrique Alves Lima <970482@tigre.dcc.unicamp.br> | Is there any function to add/remove/update cons cells (which contain | key/value pair) from a alist (association list, i guess) ? Ordinary list manipulation functions apply. | Example : | | (setq alist '((name . "John") (age . 21))) | | Now i want to modify John´s age. How can i do this ? How do you look it up to begin with? The general answer is to use setf with that form to set the new value. | ----------------------------------------------------------- | | ________ | | | o | __ | Daniel Henrique Alves Lima , RA:970482 | | | _O | |__| | Ciencia da Computacao 97 / Unicamp | | | ____/\ |___WW___| E-mail : 970482@dcc.unicamp.br | | | __/ / || | | | || | | | || | | | ____________||___________________________________________ | | ----------------------------------------------------------- Drop this. #:Erik -- Does anyone remember where I parked Air Force One? -- George W. Bush