2024-08-23 23:28:29 +00:00
|
|
|
;;((fn (f y) (f y))
|
|
|
|
;;(fn (x) (* x x))
|
|
|
|
;;2)
|
2024-08-18 19:01:40 +00:00
|
|
|
|
2024-08-23 23:28:29 +00:00
|
|
|
;;(((fn (x)
|
|
|
|
;;(fn () (* x x 2)))
|
|
|
|
;;2))
|
2024-08-22 16:21:05 +00:00
|
|
|
|
2024-08-23 23:28:29 +00:00
|
|
|
(fn fact (n)
|
|
|
|
(if (<= n 0)
|
|
|
|
1
|
|
|
|
(* n (fact (- n 1)))))
|
2024-08-23 21:21:00 +00:00
|
|
|
|
2024-08-24 23:55:11 +00:00
|
|
|
|
|
|
|
(println "12! =" (fact 12))
|