Created
March 3, 2012 17:34
-
-
Save bricklife/1967081 to your computer and use it in GitHub Desktop.
generate numbers list
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
numbers :: Int -> Int -> Int -> [[Int]] | |
numbers _ _ 0 = [[]] | |
numbers start end num = [n:ns | n <- [start..end], ns <- numbers n end (num - 1)] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment