I'm doing a function in Lisp that gets 3 numbers and says if the first is equal to the sum of the other two, the code I got was this:
(defun maior(n1 n2 n3)
(if (=(+ n2 n3)n1)
(format t "~D é maior que ~D e ~D!" n1 n2 n3)
)
But it's not running I think the problem is syntax, I want to show that the sum of n2
and n3
is equal to n1
.