On Sun, Jun 14, 2009 at 2:06 AM, Fernan Bolando fernanbola...@mailc.netwrote:
Hi all
If I have a number of list
example
list1 = [2,3]
list2 = [1,2]
list3 = [2,3,4]
list4 = [1,2,3]
I want to create a list from the list above with n elements,
non-repeating and each elements index
On Sun, Jun 14, 2009 at 4:51 PM, Miguel Mitrofanovmiguelim...@yandex.ru wrote:
ghci map reverse $ foldM (\answer list - [x:answer | x - list, not $ x
`elem` answer]) [] [[2,3], [1,2], [2,3,4], [1,2,3]]
[[2,1,4,3],[3,1,4,2],[3,2,4,1]]
On 14 Jun 2009, at 12:06, Fernan Bolando wrote:
Hi all
Hi all
If I have a number of list
example
list1 = [2,3]
list2 = [1,2]
list3 = [2,3,4]
list4 = [1,2,3]
I want to create a list from the list above with n elements,
non-repeating and each elements index represents 1 of the elements
from the corresponding list so for the above input I would get.
a
Fernan Bolando wrote:
Hi all
If I have a number of list
example
list1 = [2,3]
list2 = [1,2]
list3 = [2,3,4]
list4 = [1,2,3]
I want to create a list from the list above with n elements,
non-repeating and each elements index represents 1 of the elements
from the corresponding list so
On Sun, Jun 14, 2009 at 4:13 PM, Erik de Castro
Lopomle...@mega-nerd.com wrote:
Fernan Bolando wrote:
Hi all
If I have a number of list
example
list1 = [2,3]
list2 = [1,2]
list3 = [2,3,4]
list4 = [1,2,3]
I want to create a list from the list above with n elements,
non-repeating and
ghci map reverse $ foldM (\answer list - [x:answer | x - list, not
$ x `elem` answer]) [] [[2,3], [1,2], [2,3,4], [1,2,3]]
[[2,1,4,3],[3,1,4,2],[3,2,4,1]]
On 14 Jun 2009, at 12:06, Fernan Bolando wrote:
Hi all
If I have a number of list
example
list1 = [2,3]
list2 = [1,2]
list3 = [2,3,4]
On 14 Jun 2009, at 8:06 pm, Fernan Bolando wrote:
Hi all
If I have a number of list
example
list1 = [2,3]
list2 = [1,2]
list3 = [2,3,4]
list4 = [1,2,3]
I want to create a list from the list above with n elements,
non-repeating and each elements index represents 1 of the elements
from the
nub . concat ?
Richard O'Keefe wrote:
On 14 Jun 2009, at 8:06 pm, Fernan Bolando wrote:
Hi all
If I have a number of list
example
list1 = [2,3]
list2 = [1,2]
list3 = [2,3,4]
list4 = [1,2,3]
I want to create a list from the list above with n elements,
non-repeating and each elements
Just guessing. How do you know it's an accident?
Richard O'Keefe wrote:
On 15 Jun 2009, at 4:26 pm, Tony Morris wrote:
Prelude Data.List nub . concat $ [[2, 3], [1, 2], [2, 3, 4], [1, 2, 3]]
[2,3,1,4]
In this particular case. But that's a lucky accident.\
--
Tony Morris