Horje
prolog factorial Code Example
[Solved] - prolog factorial Code Example
Try following codes
prolog factorial
factorial(0, 1).
factorial(N, F) :- 
    N > 0, 
    Prev is N -1, 
    factorial(Prev, R), 
    F is R * N.
Date: 2022-05-21 05:02:10
Category: prolog
More for You