From: botp Date: 2010-05-02T12:02:10+09:00 Subject: Re: how can i get that kind of transpose? On Sun, May 2, 2010 at 9:59 AM, Pen Ttt wrote: > there is text1 > 1,2,3,4 > 1,2,3 > 1,2 > 1,2,3,4,5$ > what i want to get is text2: > 1,1,1,1 > 2,2,2,2 > 3,3,   3>> Matrix[[1,2,3,4], [1,2,3], [1,2]]. transpose => Matrix[[1, 1, 1], [2, 2, 2], [3, 3, nil], [4, nil, nil]] > 4,   4 > 5 > how to get it ? search for it first, $ qri transpose ------------------------------------------------------ Multiple choices: Array#transpose, Matrix#transpose so eg, => Matrix[[1, 3, 5], [2, 4, 6]] >> Matrix[[1,2,3,4], [1,2,3], [1,2]]. transpose => Matrix[[1, 1, 1], [2, 2, 2], [3, 3, nil], [4, nil, nil]] kind regards -botp