I have coded this function that prints-out the state of the board, but in the end, due to the fact that there isnt no return the function prints an nil!
Function:
(defun show-board (board)
(dotimes (number 8)
(dotimes (number2 8)
(let ((pos (aref board number number2)))
(cond
((equal pos 0) (format t "~a " "B"))
((equal pos 1) (format t "~a " "P"))
(t (format t "~a " "L")))))
(format t "~%")))
A board is an 8x8 array!
function call output on command lines:
B P B P B P B P
P B P B P B P B
B P B P B P B P
P B P B P B P B
B P B P B P B P
P B P B P B P B
B P B P B P B P
P B P B P B P B
NIL
How can i get rid of the NIL??