Skip to content

Instantly share code, notes, and snippets.

@rodrigovidal
Created October 17, 2011 03:09
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 rodrigovidal/1291856 to your computer and use it in GitHub Desktop.
Save rodrigovidal/1291856 to your computer and use it in GitHub Desktop.
Fatoração
let factorize n =
let rec find i =
if i >= n then None
elif (n % i = 0) then Some(i, n/i)
else find(i+1)
find 2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment