I have two different list ... I want to allocate same indexes in large one to another in python | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
0

I have two different list ... I want to allocate same indexes in large one to another in python

a=[2, 3, 1] b=[6, 1, 7, 6, 1, 7, 1] I want to allocate same indexes in b to a thanks

28th Jan 2017, 6:58 PM
voryamiraki
voryamiraki - avatar
7 Respostas
0
what that means?
28th Jan 2017, 7:02 PM
Pankaj Vaghela
Pankaj Vaghela - avatar
0
for example I want to assign index of every 6 in "b" to index of first in "a"....and every 1 in "b" to index of third "a" .... like this 0, 3 => 0 1, 4, 6 => 2
28th Jan 2017, 7:14 PM
voryamiraki
voryamiraki - avatar
0
sorry but I don't think that's possible
28th Jan 2017, 7:17 PM
Pankaj Vaghela
Pankaj Vaghela - avatar
0
every question have a answer.... maybe more...
28th Jan 2017, 7:20 PM
voryamiraki
voryamiraki - avatar
0
first of all I ain't able to understand what you want to do
28th Jan 2017, 7:22 PM
Pankaj Vaghela
Pankaj Vaghela - avatar
0
I solved it with for loops. ...thanks
28th Jan 2017, 8:55 PM
voryamiraki
voryamiraki - avatar
0
plz share your code
28th Jan 2017, 9:08 PM
Pankaj Vaghela
Pankaj Vaghela - avatar