RAD Studio |  |

Equality Operators

There are two equality operators: == and !=. They test for equality and inequality between arithmetic or pointer values, following rules very similar to those for the relational operators.

Note: Notice that ==
and != have a lower precedence than the relational operators < and >, <=, and >=. Also, == and != can compare certain pointer types for equality and inequality where the relational operators would not be allowed. The syntax is
Copy Code

    equality-expression:==!=
    relational-expression
    equality-expression == relational-expression
    equality-expression != relational-expression

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!