mirror of
https://github.com/HigherOrderCO/Kind.git
synced 2024-09-11 20:47:25 +03:00
8 lines
222 B
Plaintext
8 lines
222 B
Plaintext
List.app
|
|
: ∀(A: *) ∀(B: *) ∀(f: ∀(x: A) B) ∀(x: (List A))
|
|
(List B)
|
|
= λA λB λf λx
|
|
let P = λx (List B)
|
|
let cons = λh λt (List.cons B (f h) (List.app A B f t))
|
|
let nil = (List.nil B)
|
|
(~x P cons nil) |