11.3.108 < /2 [ISO]

Synopsis

+Expr1 < +Expr2

Evaluates Expr1 and Expr2 as arithmetic expressions. The goal succeeds if the result of evaluating Expr1 is strictly less than the result of evaluating Expr2.

Arguments

Expr1
expr, must be ground
Expr2
expr, must be ground

Description

Evaluates Expr1 and Expr2 as arithmetic expressions and compares the results.

Exceptions

Arithmetic errors (see ref-ari-exc).

Examples

     | ?- 23 + 2.2  <  23 - 2.2.
     
     yes
     | ?- X = 31, Y = 25, X + Y  <  X - Y
     
     no

See Also

ref-ari


Send feedback on this subject.