On Wed, May 27, 2009 at 7:30 AM, Elise Langham (Elanit)
<[email protected]> wrote:
> How do i create a jagged array in IronPython ?
>
> I’ve tried various methods:
> jagArray = Array[Array[int]]( ( (1,2), (1,2), (1,2,3), (1,2,3,4) ))
I'd write a helper method:
def make_jagged(T, v):
return Array[Array[T]]([Array[T](x) for x in v])
And then say "make_jagged(int, ((1, 2), (1, 2, 3), (1,)))"
--
Curt Hagenlocher
[email protected]
_______________________________________________
Users mailing list
[email protected]
http://lists.ironpython.com/listinfo.cgi/users-ironpython.com