let fact n = 
    let rec fact_tailrec n acc =
        if (n <= 0) then acc
        else fact_tailrec (n-1) (n*acc)
    
    fact_tailrec n 1

[<EntryPoint>]
let main args = 
    System.Console.WriteLine ("Tail recursive: {0}", fact (5))
    0

