Re: comple list slices
- From: shandy.b@xxxxxxxxx
- Date: 28 Feb 2006 07:29:06 -0800
A couple questions:
1- what is j?
2- what does the rows[x][y] object look like? I assume it's a dict
that has a "rowspan" key. Can rows[x][y]["rowspan"] sometimes be 0?
Perhaps you're looking for something like this:
rowgroups = []
rowspan = 0
for i in range( len(rows) ):
if rowspan <= 0:
rowspan = rows[j][0]["rowspan"]
if rowspan == 0:
rowspan = 1
rowgroups.append(rows[ i : i + rowspan ])
rowspan -= 1
-sjbrown
.
- Follow-Ups:
- Re: comple list slices
- From: William Meyer
- Re: comple list slices
- References:
- comple list slices
- From: William Meyer
- comple list slices
- Prev by Date: looking for help about python-sane
- Next by Date: Re: Python advocacy in scientific computation
- Previous by thread: comple list slices
- Next by thread: Re: comple list slices
- Index(es):