j
k
j a
j l
Mirko Rahn writes: (snip)
Correct (and more natural): nOf 0 _ = [[]] nOf n (x:xs) = map (x:) (nOf (n-1) xs) ++ nOf n xs nOf _ [] = []
Correct (and more natural):
nOf 0 _ = [[]] nOf n (x:xs) = map (x:) (nOf (n-1) xs) ++ nOf n xs nOf _ [] = []
Thanks very much - in both claims you're indeed correct. -- Mark
Back to the thread
Back to the list