Best Answer

FoxPro doesn't have any special factorial function, so you would have to write your own factorial function. It's fairly easy, for example:

function factorial

lparameters n

result = 1

for i = 1 to n

result = result * n


return result

If you have an older version of FoxPro, you may need to replace "lparameters" by "parameters".

Or even simpler, with recursion:

function factorial

lparameters n

return iif(n<=1, n, n*factorial(n-1))

User Avatar

Wiki User

7y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you find factorial in fox pro?
Write your answer...
Still have questions?
magnify glass