Intel fortran-80 manual IF FLAG1 .EQV. FLAG2 RETURN

Models: fortran-80

1 130
Download 130 pages 742 b
Page 23
Image 23
IF (FLAG1 .EQV. FLAG2) RETURN

FORTRAN-80

FORTRAN Concepts

The following statement returns whenever the two logical operands are logically equivalent.

IF (FLAG1 .EQV. FLAG2) RETURN

The value when two logical operands are combined by .NEQV. is as follows:

OP1

OP2

OP1 .NEQV. OP2

TRUE

TRUE

FALSE

TRUE

FALSE

TRUE

FALSE

TRUE

TRUE

FALSE

FALSE

FALSE

If both operands are logically different, the logical expression is true.

The following statement continues execution if the two operands are not equivalent.

IF (FLAG1 .NEQV. FLAG2) CONTINUE

2.2.4.6 Precedence of Operators.

Expressions are generally evaluated left to right. Operators with higher precedence are evaluated before other operators that immediately precede or follow them. When two operators have equal precedence, the leftmost is evaluated first.

2-11

Page 23
Image 23
Intel fortran-80 manual IF FLAG1 .EQV. FLAG2 RETURN