Not Equal operator (!=)

Description:

Performs a comparison between two integer, float or string expressions.
The returned value is 1 if both expressions have different values, 0 otherwise.

Format:

result = expression1 != expression2;

Parameters:

expression1

An integer, float or string expression.

expression2

An integer expression if expression1 is an integer expression, a float expression if expression1 is a float expression, a string expression if expression1 is a string expression.

Example:

integer i;

i = (5 != 10);
if ( i == 1 )
    log "5 != 10";
else
    log "5 == 10";
endif

i = (2.1 != 1.0);
if ( i == 1 )
    log "2.1 != 1.0";
else
    log "2.1 == 1.0";
endif

i = ("one" != "one");
if ( i == 1 )
    log "one != one";
else
    log "one == one";
endif

Output:

5 != 10
2.1 != 1.0
one == one





Go back to the Learning center:


Copyright © AgileLoad. All rights reserved.
Agile Load testing tool| Contact AgileLoad | Terms of Use | Sitemap