Contents | Prev | Next

8.2.3.2 Is equal

Description

The = operator takes two operands and compares them for equality. If one operand is of integral type and the other is of real type then the integral operand is converted to real before the comparison is made. The result of this operation is of boolean type, and is true if the operands are equal, and false otherwise.

Example

   23 =   23    results in true
  -23 =  -23    results in true
   23 = 23.0    results in true
 23.0 =   23    results in true
   23 =  -23    results in false
    2 =    3    results in false
    3 =    2    results in false

Contents | Prev | Next