Alex Martelli wrote: > Well, x=23 on one side, and x[]=23 aka x[()]=23 on the other, have > drastically different semantics. Indexing refers to the contents of > the zero-dimensional container, rather than to a name to which the > container happens to be bound (but isn't any more, once one assigns to > that name rather than to an indexing thereof). It's not clear to me that a 0-D array should be regarded as a container holding a single item, rather than just an item on its own. Think about how you get from an N dimensional array to an N-1 dimensional array: you index it, e.g. A2 = [[1, 2], [3, 4]] # a 2D array A1 = A2[1] # a 1D array A0 = A1[1] # a 0D array??? print A0 What do you think this will print? -- Greg
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4