Two-dimensional arrays
Terry Reedy
tjreedy at udel.edu
Tue May 27 17:55:54 EDT 2003
"monsterkodi" <monsterkodi at gmx.net> wrote in message
news:d9608a84.0305270903.361a751f at posting.google.com...
[in response to my response]
> I just think that this way of constructing a multidimensional array
> isn't exactly what I would call a 'very clear and intuitive syntax'.
ok
> Maybe a built in function
> array(width,height,depth=0,value=None)
> which returns a simple 2 or 3-dimensional array, internally
> represented
> as lists of lists (of lists)
"Carl Banks" <imbosol at aerojockey.com> wrote in message
news:u6OAa.21293$fT5.1655 at nwrdny01.gnilink.net...
[also in response to me]
> I think a builtin multidimensional array factory would be nice. I
> suggest this:
> multiarray(dims,initializer=None,func=None)
> dims is a sequence of array dimensions.
> initializer is an initializer value.
Interesting convergence of responses. During the pydev discussion the
new sum() builtin, someone suggested that it might be nice to have a
simple statistics module (which is where min(), max(), and sum() would
belong). If such a thing were to come to pass, an array function
should certainly be included.
Terry J. Reedy
More information about the Python-list
mailing list