Solution exercises from P01 to P07

This commit is contained in:
Fabio Scotto di Santolo
2025-09-05 11:59:55 +02:00
commit 54214ae0aa
7 changed files with 64 additions and 0 deletions

9
p01.el Normal file
View File

@@ -0,0 +1,9 @@
;; P01 (*) Find the last box of a list
(defun my-last (lst)
(cond
((eq lst '()) '())
((eq (cdr lst) '()) lst)
(t
(my-last (cdr lst)))))
(my-last '(a b c d)) ; '(d)