flebber wrote:
> Thank you for the replies.
>
> Looking at the replies I am wondering which solution is more scalable. At
> the moment it is only 2 nested lists but what about 5, 10, 20 or more?
>
> Should I start looking into numpy to handle this or will list
> comprehension
> >>> [ [ x + y f
On Wed, 20 Nov 2013 12:05:38 -0800, flebber wrote:
> Thank you for the replies.
>
> Looking at the replies I am wondering which solution is more scalable.
> At the moment it is only 2 nested lists but what about 5, 10, 20 or
> more?
>
> Should I start looking into numpy to handle this or will lis
Thank you for the replies.
Looking at the replies I am wondering which solution is more scalable. At the
moment it is only 2 nested lists but what about 5, 10, 20 or more?
Should I start looking into numpy to handle this or will list comprehension
>>> [ [ x + y for x, y in zip(x,y) ] for x, y
flebber writes:
> If
>
> c = map(sum, zip([1, 2, 3], [4, 5, 6]))
>
> c
> Out[7]: [5, 7, 9]
>
> why then can't I do this?
>
> a = ([1, 2], [3, 4])
>
> b = ([5, 6], [7, 8])
>
> c = map(sum, zip(a, b))
> ---
> TypeError
flebber wrote:
> If
>
> c = map(sum, zip([1, 2, 3], [4, 5, 6]))
>
> c
> Out[7]: [5, 7, 9]
>
> why then can't I do this?
>
> a = ([1, 2], [3, 4])
>
> b = ([5, 6], [7, 8])
>
> c = map(sum, zip(a, b))
>
---
> TypeError