Idris2-boot/tests/idris2/import002/Nat.idr

11 lines
129 B
Idris
Raw Normal View History

2019-06-24 02:12:58 +03:00
module Nat
public export
data Nat = Z | S Nat
public export
plus : Nat -> Nat -> Nat
plus Z y = y
plus (S k) y = S (plus k y)