On 27/07/2010 14:32, Vikram K wrote: > how do i obtain from the above the following nested list: Here's another solution, though possibly not a neat one: > http://dpaste.com/222375/ All the best, Alex