<div dir="ltr"><div class="gmail_default" style="font-family:georgia,serif;font-size:small">Thank you all!! </div><div class="gmail_default" style="font-family:georgia,serif;font-size:small"><br></div><div class="gmail_default" style="font-family:georgia,serif;font-size:small">Got it working with Data.List.transpose</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, May 18, 2015 at 5:09 PM, Henk-Jan van Tuyl <span dir="ltr"><<a href="mailto:hjgtuyl@chello.nl" target="_blank">hjgtuyl@chello.nl</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Mon, 18 May 2015 13:23:41 +0200, Dananji Liyanage <<a href="mailto:dan9131@gmail.com" target="_blank">dan9131@gmail.com</a>> wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi All,<br>
<br>
I'm building a 9x9 grid like list, and I want to extract each column of<br>
that grid.<br>
<br>
My input is a list of integers as follows;<br>
<br>
input = [0, 0, 0, 0, 0, 0, 4, 0, 9,<br>
0, 0, 0, 0, 8, 0, 0, 5, 0,<br>
7, 0, 2, 4, 5, 3, 6, 0, 0,<br>
6, 7, 0, 0, 0, 1, 5, 0, 2,<br>
2, 0, 8, 7, 0, 4, 3, 0, 1,<br>
9, 0, 4, 5, 0, 0, 0, 8, 6,<br>
0, 0, 6, 3, 1, 9, 8, 0, 7,<br>
0, 2, 0, 0, 7, 0, 0, 0, 0,<br>
1, 0, 7, 0, 0, 0, 0, 0, 0]<br>
</blockquote>
<br></span>
Try the function chunksOf of package split[0]<br>
<br>
Regards,<br>
Henk-Jan van Tuyl<br>
<br>
<br>
[0] <a href="http://haddocks.fpcomplete.com/fp/7.8/20140916-162/split/Data-List-Split-Internals.html#v:chunksOf" target="_blank">http://haddocks.fpcomplete.com/fp/7.8/20140916-162/split/Data-List-Split-Internals.html#v:chunksOf</a><span class="HOEnZb"><font color="#888888"><br>
<br>
<br>
-- <br>
Folding@home<br>
What if you could share your unused computer power to help find a cure? In just 5 minutes you can join the world's biggest networked computer and get us closer sooner. Watch the video.<br>
<a href="http://folding.stanford.edu/" target="_blank">http://folding.stanford.edu/</a><br>
<br>
<br>
<a href="http://Van.Tuyl.eu/" target="_blank">http://Van.Tuyl.eu/</a><br>
<a href="http://members.chello.nl/hjgtuyl/tourdemonad.html" target="_blank">http://members.chello.nl/hjgtuyl/tourdemonad.html</a><br>
Haskell programming<br>
--<br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div><div><div><font face="georgia,serif">Regards, <br>Dananji Liyanage</font></div></div></div></div></div>
</div>