(defun solve () (let* ((n (read)) (a 0) (ren-like (make-array n :initial-element 0))) (dotimes (i n) (dotimes (j n) (if (equal (read) 'NYANPASS) (setf (aref ren-like j) (1+ (aref ren-like j)))))) (dotimes (i n) (if (= (- n 1) (aref ren-like i)) (cond ((= a 0) (setf a (+ i 1))) ((>= a 1) (setf a -1))))) (if (= a 0) (setf a -1)) a)) ;つかれたーーーーーーーーーーーーーーーーーーーーー ;文字列の読み込みってもっと簡単にならないんかーーーーーーーーーーーーーーーー (defun main () (format t "~A~%" (solve))) (main)