Use "n - 1I".

1
2
let rec factorial (n:bigint) : bigint = if n=0I then 1I else n*factorial(n - 1I)

Kind regards

Don

By on 5/25/2007 2:26 PM ()

Doh! Of course. It wasn't clear to me from the error message, but now that you point out my mistake, it's quite obvious. Thanks!

By on 5/25/2007 3:04 PM ()
IntelliFactory Offices Copyright (c) 2011-2012 IntelliFactory. All rights reserved.
Home | Products | Consulting | Trainings | Blogs | Jobs | Contact Us | Terms of Use | Privacy Policy | Cookie Policy
Built with WebSharper