Rev 100 | Blame | Compare with Previous | Last modification | View Log | RSS feed
;;; Written By: Ira Snyder
;;; Due Date: Wed 02-02-2005
;;; Homework #: HW05
;;; License: Public Domain
;;;
;;; Count the number of numbers in an arbitrary
;;; depth expression
;;;
(defun COUNT# (E)
(cond
((numberp E) 1)
((atom E) 0)
(t (+ (COUNT# (car E))
(COUNT# (cdr E))))
)
)