type exp = Zero | Var of string
type env = (string * int) list
The value zero
in the definition of eval
is not defined. Since eval
returns an int
, why not replace zero
by 0
?
Hope that helps!
type exp = Zero | Var of string
type env = (string * int) list
The value zero
in the definition of eval
is not defined. Since eval
returns an int
, why not replace zero
by 0
?
Hope that helps!