2024-04-06 00:55:35 -04:00
|
|
|
<> (add (s ?x) (s ?y)) (s (add ?x (s ?y)))
|
|
|
|
<> (add (s ?x) (0)) (s ?x)
|
|
|
|
<> (add (0) (s ?y)) (s ?y)
|
2024-04-06 00:34:17 -04:00
|
|
|
<> (add (0) (0)) (0)
|
2024-04-06 12:10:19 -04:00
|
|
|
<> (sub (s ?x) (s ?y)) (sub ?x ?y)
|
|
|
|
<> (sub (s ?x) (0)) (s ?x)
|
|
|
|
<> (sub (0) (s ?y)) (s ?y)
|
|
|
|
<> (sub (0) (0)) (0)
|
|
|
|
<> (mul (s ?x) (s ?y)) (add (s ?x) (mul (s ?x) (sub (s ?y) (s (0)))))
|
2024-04-06 13:59:44 -04:00
|
|
|
<> (mul (s ?x) (s (0))) (s ?x)
|
|
|
|
<> (mul (s (0)) (s ?y)) (s ?y)
|
2024-04-06 12:10:19 -04:00
|
|
|
<> (mul (s ?x) (0)) (0)
|
|
|
|
<> (mul (0) (s ?x)) (0)
|
2024-04-06 00:34:17 -04:00
|
|
|
<> (?x + ?y) (add ?x ?y)
|
2024-04-06 12:10:19 -04:00
|
|
|
<> (?x - ?y) (sub ?x ?y)
|
|
|
|
<> (?x * ?y) (mul ?x ?y)
|
2024-04-06 00:34:17 -04:00
|
|
|
<> (factorial (s (0))) ((s (0)))
|
2024-04-06 00:55:35 -04:00
|
|
|
<> (factorial (s ?x)) (((s ?x) * factorial ((s ?x) - (s (0)))))
|
2024-04-06 00:34:17 -04:00
|
|
|
|
2024-04-06 00:55:35 -04:00
|
|
|
factorial (s (s (s (s (s (0))))))
|