Advertisement
Guest User

Untitled

a guest
Aug 25th, 2014
228
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
F# 0.23 KB | None | 0 0
  1. open System
  2. open System.Numerics
  3.  
  4.  
  5. let rec FactorialBigInteger(n: bigint): bigint =  
  6.     match n with  
  7.     | 1 -> bigint(1)  
  8.     | n -> bigint(n) * FactorialBigInteger(n - 1)  
  9.  
  10. let result = factorial 250000
  11. printfn "%A" result
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement