j

Sunday, 13 December 2015

What is Relational Operators ?

Relational Operators
                The relational operators are used to specify conditions in the programs. A relational operator compares two values. It produces result as true of false. The relational operators are sometimes called conditional operators or comparison operators as they test conditions that are either true or false. C++ provides the following relational operators.
Operators
Description
Greater than operators returns true if the value if left side of > is greater than the value of right side. Otherwise returns false
<
Less than operators returns true if the value of left side of < is less than the value of right side. Otherwise return false
==
Equal to operators returns true if the values if both sides is equal. Otherwise return false
>=
Greater than or equal to operators returns true if the value on left side of >= is greater than or equal to the value of right side. Otherwise returns false
<=
Less than or equal to operators returns true if the value on left side of <= is less than or equal to the value of right side. Otherwise returns false.
!=
The not equal to operators returns true if the value on left side of! = is not equal to the value on right side. Otherwise returns false


Subscribe to this Blog via Email :