Files
RustAst/examples/hof.myc
T
2026-02-17 23:19:08 +01:00

10 lines
165 B
Plaintext

;; Higher-Order Function Example
;; Benchmark: 8.4us
;; Output: 25
(do
(def apply (fn [f x] (f x)))
(def square (fn [x] (* x x)))
(apply square 5)
)