; n * k 粒あるので 家族の年齢を引き続け ; 負の値になったら 0 それ以外ならその数を出力する (defun main () (let* ((k (read)) (n (read)) (f (read)) (g (lambda (x) (if (minusp x) 0 x))) (result (* k n))) (dotimes (_ f) (decf result (read))) ; funcall function &rest args => result* ; function を args を引数として実行する (princ (funcall g result)) (terpri))) (main)