Skip to content

Instantly share code, notes, and snippets.

@camilopayan
Created February 22, 2010 15:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save camilopayan/311164 to your computer and use it in GitHub Desktop.
Save camilopayan/311164 to your computer and use it in GitHub Desktop.
//////////Problem 6
let rec powerset = function
| [] -> [[]]
| h::t -> List.fold (fun xs t -> (h::t)::t::xs) [] (powerset t);;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment