MathGroup Archive 2005

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

Search the Archive

Re: Sorting nested list

I have a similar problem, I need to sort the same kind of list

{{a,{2,4,1.,...}}, {c, {1,2,...}},{b,{3.2,-2,.­..}}}

but I need to sort it based on the first element of each subarray,
while keeping the second element the same.

I did a pretty ugly solution (like 12 lines of code).  Is there a
quicker more elegant way to sort this?

  • Prev by Date: polynomialreduce
  • Next by Date: pure functions vs. functions
  • Previous by thread: Re: Sorting nested list
  • Next by thread: Re: Re: Sorting nested list