RosettaCodeData/Task/A+B/Ol/a+b.ol

13 lines
261 B
Text
Raw Permalink Normal View History

2017-09-23 10:01:46 +02:00
; simplest
(+ (read) (read))
; safe
(let ((a (read))
(b (read)))
(if (not (number? a))
(runtime-error "a is not a number! got:" a))
(if (not (number? b))
(runtime-error "b is not a number! got:" b))
(print a " + " b " = " (+ a b)))