<?
 /import(core)

 # Error Reporting

 error-message(value) : {
     value !- "" ->
         self @ context

     "Not a valid number!" ->
         self @ context when Invalid-Integer

     "Number must be greater than or equal to 0!" ->
         self @ context when Negative-Number
 }

 # Input Validation

 Negative-Number  <- &(Negative-Number)
 Negative-Number! <- fail(Negative-Number)

 validate(x) :
     case(
         x >= 0 : x,
         Negative-Number!
     )

 valid-int(value) : {
     x <- int(va