Re: Joining lists
- To: mathgroup at smc.vnet.net
- Subject: [mg37878] Re: Joining lists
- From: Martin Johansson <martin.n.johansson at emw.ericsson.se>
- Date: Sat, 16 Nov 2002 01:15:47 -0500 (EST)
- Organization: Ericsson Microwave Systems AB
- References: <ar0033$b1p$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
Hi! "Pigeon, Robert" wrote: > > Here what I am trying to do: > a={1,2,3}; > b={4,5,6}; > c={{a[[1]],b[[1]]},{a[[2]],b[[2]]},{a[[3]],b[[3]]}} > {{1,4},{2,5},{3,6}} > > I tried: Do[{{a[[i]],b[[i]]}},{i,3}] And it is not working. You have already received some suggestions. Here are two other ways that could be used: Table[{a[[i]], b[[i]]}, {i, Length[a]}] {a[[#]], b[[#]]} & /@ Range[Length[a]] Ciao, Martin