How do you write Not equals

Page 2 - Seeking answers? Join the AnandTech community: where nearly half-a-million members share solutions and discuss the latest tech.

LiuKangBakinPie

Diamond Member
Jan 31, 2011
3,910
0
0
In C expressions, you can assume that *, /, and % come before + and -. Put parentheses around everything else.
 

Lemon law

Lifer
Nov 6, 2005
20,984
3
0
In my mind, this is somewhat a tempest in a tea pot thread, because human being easily understand the symbol providing they understand the symbol, thus effortlessly handling the concept of inequality. In the USA, I might expect the average 6 year child to understand what = means. But given all the various symbols for inequality, I might not make that same assumption at age 6.

Explaining it to a computer is much harder, and the more precisionion we use, the harder it is. For example if I use an integer has a data type in C, depending on the rounding methods used, 2.45 would be equal to 1.55. And at one time, I was calculating circle circle intersections, had the equations programmed in, and was debugging the program while using the long double data type for all calculations. And testing the tangent intersection at one and only one point. Ad long as I used say, one corcle of radius 1 centered at (0,0) and another circle centered at (3,0) of radius 2, the program returned the correct answerof one and only one point of intersection at (1,0). But as soon as I scaled the same easily solved problem mentally by multiplying up or down, by some fractional multiple, say, 1/2, the program always bombed. And a little debugging showed why. Given the equations I was using, the test for the tangent case, used a quadratic equation where the the test for exact tangent was given by the the square root of quantity B squared minus 4ac equaling exactly zero. But when the computer processed it, even using long doubles, debugging showed the computer making small calculation errors way out at the 18'th digit base 10. And for some reason the computer computed answer was always negative, as the program bombed because there is no solution for the square root of a negative number.

After that it was easy to write an error handler, and tell the computer if the difference between the numbers were less that 10 to the minus 17, assume they are equal.
 
Last edited:

LiuKangBakinPie

Diamond Member
Jan 31, 2011
3,910
0
0
Excel
Equals (=)
Less than (<)
Less than or equal to (<=)
Greater than (>)
Greater than or equal to (>=)
Not equal to (<>)

C#
== Equal
!= Not equal
> Greater than
>= Greater than or equal to
< Less than
<= Less than or equal to

Mathematical Symbols
&#8800; not equal
< less than
> greater than
&#8804; less than or equal to
&#8805; greater than or equal to

Matlab/Octave
~=

One of the oldest ones
<>
 

Dr. Zaus

Lifer
Oct 16, 2008
11,770
347
126
Excel
Equals (=)
Less than (<)
Less than or equal to (<=)
Greater than (>)
Greater than or equal to (>=)
Not equal to (<>)

C#
== Equal
!= Not equal
> Greater than
>= Greater than or equal to
< Less than
<= Less than or equal to

Mathematical Symbols
&#8800; not equal
< less than
> greater than
&#8804; less than or equal to
&#8805; greater than or equal to

Matlab/Octave
~=

One of the oldest ones
<>

A~=~!=a
 

Ichinisan

Lifer
Oct 9, 2002
28,298
1,234
136
I started with BASIC, so <> used to make sense. Haven't done BASIC in a long time, and I've grown to like != better anyway...because you can also do !(condition) for true/false (boolean) stuff.
 

Dr. Zaus

Lifer
Oct 16, 2008
11,770
347
126
Technically speaking, the answer to the question is, within the context of computer use,:
 

lokiju

Lifer
May 29, 2003
18,536
5
0
<> which is what I use often when running queries to show everything but x.
 
sale-70-410-exam    | Exam-200-125-pdf    | we-sale-70-410-exam    | hot-sale-70-410-exam    | Latest-exam-700-603-Dumps    | Dumps-98-363-exams-date    | Certs-200-125-date    | Dumps-300-075-exams-date    | hot-sale-book-C8010-726-book    | Hot-Sale-200-310-Exam    | Exam-Description-200-310-dumps?    | hot-sale-book-200-125-book    | Latest-Updated-300-209-Exam    | Dumps-210-260-exams-date    | Download-200-125-Exam-PDF    | Exam-Description-300-101-dumps    | Certs-300-101-date    | Hot-Sale-300-075-Exam    | Latest-exam-200-125-Dumps    | Exam-Description-200-125-dumps    | Latest-Updated-300-075-Exam    | hot-sale-book-210-260-book    | Dumps-200-901-exams-date    | Certs-200-901-date    | Latest-exam-1Z0-062-Dumps    | Hot-Sale-1Z0-062-Exam    | Certs-CSSLP-date    | 100%-Pass-70-383-Exams    | Latest-JN0-360-real-exam-questions    | 100%-Pass-4A0-100-Real-Exam-Questions    | Dumps-300-135-exams-date    | Passed-200-105-Tech-Exams    | Latest-Updated-200-310-Exam    | Download-300-070-Exam-PDF    | Hot-Sale-JN0-360-Exam    | 100%-Pass-JN0-360-Exams    | 100%-Pass-JN0-360-Real-Exam-Questions    | Dumps-JN0-360-exams-date    | Exam-Description-1Z0-876-dumps    | Latest-exam-1Z0-876-Dumps    | Dumps-HPE0-Y53-exams-date    | 2017-Latest-HPE0-Y53-Exam    | 100%-Pass-HPE0-Y53-Real-Exam-Questions    | Pass-4A0-100-Exam    | Latest-4A0-100-Questions    | Dumps-98-365-exams-date    | 2017-Latest-98-365-Exam    | 100%-Pass-VCS-254-Exams    | 2017-Latest-VCS-273-Exam    | Dumps-200-355-exams-date    | 2017-Latest-300-320-Exam    | Pass-300-101-Exam    | 100%-Pass-300-115-Exams    |
http://www.portvapes.co.uk/    | http://www.portvapes.co.uk/    |