|
[Date Index]
[Thread Index]
[Author Index]
dictionaries?
- To: mathgroup at smc.vnet.net
- Subject: [mg20413] dictionaries?
- From: Joe Strout <joe at strout.net>
- Date: Tue, 26 Oct 1999 00:33:00 -0400
- Organization: The Salk Institute
- Sender: owner-wri-mathgroup at wolfram.com
In Python, there's an extremely handy datatype called a "dictionary"
which implements a many-to-1 mapping between keys (which can be any
hashable type) and values (which can be anything). E.g.:
> d = {"one":1, "two":2}
> d["one"]
1
> d["three"]
(key not found)
I'm looking for something similar in Mathematica -- it's a great way to
organize lists of parameters, without having to worry about the order
in which they are listed.
I've searched the online help and flipped through the Mathematica book,
but I can't find anything like this. Have I missed something?
Thanks,
-- Joe
--
,------------------------------------------------------------------.
| Joseph J. Strout Biocomputing -- The Salk Institute |
| joe at strout.net http://www.strout.net |
`------------------------------------------------------------------'
Check out the Mac Web Directory! http://www.strout.net/macweb.cgi
Prev by Date:
Basic Laplace Transforms
Next by Date:
boundary conditions
Previous by thread:
Re: Basic Laplace Transforms
Next by thread:
Re: dictionaries?
|