[Home]
[Edit this page]
[Recent Changes]
[Special Pages]
[Help]
CppLessThanOperator
It opposite operator is the greater than operator, >.
The six logical-test operators are:
[Edit this page] [Page history] [What links here] [Discuss this topic] [Printer Friendly]
CppLessThanOperator
(C++) < operator
The less-than/lower-than operator is used to compare two values. It is very commonly used in if-statements.
if (x < y) { /* what to do if x is lower then y */ }
else { /* what to do if x is equal or higher than y */ }
It opposite operator is the greater than operator, >.
The six logical-test operators are:
- ==, equal operator
- !=, not equal operator
- <, less than operator
- >, greater than operator
- <=, less than or equal
- >=, greater than or equal
'Less than operator' links
[Edit this page] [Page history] [What links here] [Discuss this topic] [Printer Friendly]
