<<< Relational Operators | Index | if-else statement >>> |
The following boolean expressions can be useful in many control statements such as if that compare numeric data:
discountPercent == 2.3 // equal to a numeric literal subtotal != 0 // not equal to a numeric literal years > 0 // greater than a numeric literal i < months // less than a numeric variable subtotal >= 500 // greater than or equal to a numeric literal quantity <= reorderQty // less than or equal to a numeric variable
<<< Relational Operators | Index | if-else statement >>> |