cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
Beginners
Operator "Not equal to"
Operator "Not equal to"
Jun 12, 2012 at 2:57am UTC
scout51
(20)
Just to get this concept straight...
The expresion !(x > 10), is equivalent to (x < 10) ?
or the expresion means that, if !(x >10) , can be (X <= 10) ?
Thanks in advance for your help.
Last edited on
Jun 12, 2012 at 3:01am UTC
Jun 12, 2012 at 3:02am UTC
firedraco
(6243)
!(x>10) means x <= 10.
Draw a number line if it helps.
Jun 12, 2012 at 3:27am UTC
scout51
(20)
ok, so under the same concept.. the expresion !(x< 0) is true only if
(X >= 0) ?
Jun 12, 2012 at 3:46am UTC
JLBorges
(13770)
If
a
and
b
are two integers:
( a>b )
implies
( b<a )
!(a>b )
implies both
( b>=a )
and
( a<=b )
( a>b ) || ( b>a )
implies
( b!=a )
!(a>b ) && !(b>a )
implies
( b==a )
Note: the relation
>
on the set of integers imposes a strict ordering.
http://mathworld.wolfram.com/StrictOrder.html
It is irreflexive:
( a>a )
is
false
for every
a
Asymmetric: if
( a>b )
is
true
, then
( b>a )
must be
false
for every
a
,
b
Transitive: if both
( a>b )
and
( b>c )
are
true
, then
( a>c )
must be
true
for every
a
,
b
,
c
Jun 12, 2012 at 4:10am UTC
scout51
(20)
Thank you for your help guys, it really helped a lot.
Topic archived. No new replies allowed.