Re[4]: Re: Comprehensions
Lenard Lindstrom <[email protected]> Wed, 14 Jul 2004 18:27:09 -0700 (Pacific Daylight Time)
| Newsgroups | gmane.comp.lang.prothon.user |
|---|---|
| Message-ID | <Mahogany-0.66.0-4294685873-20040714-200731.00@pop3.norton.antivirus> |
On Wed, 14 Jul 2004 11:43:55 -0700 Mark Hahn <[email protected]> wrote: > > Slice lists and ellipses in subsripts for user defined sequences. > > Hmm. Are these in Python? If not, then can you elaborate? > I believe they are for use by the Numeric module. Slice lists: seq[1, 4, 8:10] Since in Python it is the comma, not parenthesis, that create a tuple, having comma separated items in a subscript passes a tuple of items to the subscript handler method. ellispses: seq[...] Passes a special Ellipses object to the subscript method. These are covered in section 5.3.3, Slices, of the Python Language Reference. They are not currently used by Python lists and tuples. Lenard Lindstrom <[email protected]>