harryos wrote:
> I have 2 lists of numbers,say
> x=[2,4,3,1]
> y=[5,9,10,6]
> I need to create another list containing
> z=[2*5, 4*9, 3*10, 1*6] ie =[10,36,30,6]
>
> I did not want to use numpy or any Array types.I tried to implement
> this in python .I tried the following
>
> z=[]
> for a,b in
On Sep 20, 3:02 pm, harryos wrote:
> hi
> I have 2 lists of numbers,say
> x=[2,4,3,1]
> y=[5,9,10,6]
> I need to create another list containing
> z=[2*5, 4*9, 3*10, 1*6] ie =[10,36,30,6]
>
> I did not want to use numpy or any Array types.I tried to implement
> this in python .I tried the followin
On Sep 20, 7:28 pm, Bruno wrote:
>> A list comp comes to mind, as well as using itertools.izip
thanks Bruno,thanks Gary..
Should have thought of list comprehension..
Thanks for the pointer about izip
harry
--
http://mail.python.org/mailman/listinfo/python-list
harryos writes:
> hi
> I have 2 lists of numbers,say
> x=[2,4,3,1]
> y=[5,9,10,6]
> I need to create another list containing
> z=[2*5, 4*9, 3*10, 1*6] ie =[10,36,30,6]
>
> I did not want to use numpy or any Array types.I tried to implement
> this in python .I tried the following
>
> z=[]
> for a
On 09/20/2010 07:02 AM, harryos wrote:
hi
I have 2 lists of numbers,say
x=[2,4,3,1]
y=[5,9,10,6]
I need to create another list containing
z=[2*5, 4*9, 3*10, 1*6] ie =[10,36,30,6]
I did not want to use numpy or any Array types.I tried to implement
this in python .I tried the following
z=[]
for
harryos a écrit :
hi
I have 2 lists of numbers,say
x=[2,4,3,1]
y=[5,9,10,6]
I need to create another list containing
z=[2*5, 4*9, 3*10, 1*6] ie =[10,36,30,6]
I did not want to use numpy or any Array types.I tried to implement
this in python .I tried the following
z=[]
for a,b in zip(x,y):
hi
I have 2 lists of numbers,say
x=[2,4,3,1]
y=[5,9,10,6]
I need to create another list containing
z=[2*5, 4*9, 3*10, 1*6] ie =[10,36,30,6]
I did not want to use numpy or any Array types.I tried to implement
this in python .I tried the following
z=[]
for a,b in zip(x,y):
z.append(a*b)
Th