MathGroup Archive 2007

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Iterate through a list help


Just pick out the first element in each sub-list:

In[3]:=
list={{1,2,3},{4,5,6},{9,3,12}};

newlist=First /@ list

Out[4]=
{1,4,9}


  • Prev by Date: Re: comments
  • Next by Date: Re: Version 6.0 Problems
  • Previous by thread: Re: Iterate through a list help
  • Next by thread: modify elements of arb.dimensionality matrices