Project Euler 3: Getting the largest prime factor of a number
There's nothing really wrong with your code but here's a slight rewrite using pattern matching which is arguably a more functional style than if ... then ... else. I also rearranged the args to eliminate the unnecessary n parameter on the outer function.

let primeFactors = 
    let rec recPrimeFactors primes i = function
        | n when 2L*i &gt; n -&gt; n::primes
        | n -&gt; match n % i with
               | 0L -&gt; recPrimeFactors (i::primes) 2L (n / i)
               | _ -&gt; recPrimeFactors primes (i + 1L) n
    recPrimeFactors [] 2L

600851475143L |&gt; primeFactors |&gt; List.head |&gt; printfn "%d"