2021-04-09 00:01:27 +02:00
|
|
|
(plan 1)
|
|
|
|
|
2021-04-06 22:41:49 +02:00
|
|
|
(defun range (start end)
|
|
|
|
(do ((lst (list) (cons i lst)) (i start (+ 1 i))) ((= i end) lst)))
|
|
|
|
|
|
|
|
(let ((result (reduce + (filter (lambda (x) (or (zerop (mod x 3)) (zerop (mod x 5)))) (range 1 1000)))))
|
|
|
|
(expect "euler1 - result is 233168" (= result 233168)))
|