The following table shows the precedence of all intrinsic and defined operators:
Precedence of Expression Operators
Category | Operator | Precedence |
---|---|---|
Defined Unary Operators | Highest | |
Numeric | ** |
|
Numeric | * or / |
|
Numeric | Unary + or - |
|
Numeric | Binary + or - |
|
Character | // |
|
Relational | .EQ., .NE., .LT., .LE., .GT., .GE. = =, /=, <, <=, >, >= |
|
Logical | .NOT. |
|
Logical | .AND. |
|
Logical | .OR. |
|
Logical | .XOR., .EQV., .NEQV. |
|
Defined Binary Operators | Lowest |