Performs logical negation on an expression.
Syntaxresult = ! expression
var x = 5;
var y = 7;
var z;
z = ! (x = y);
z = ! (y > x);
Remarks
The following table illustrates how result is determined.
Ifexpression
is Then result
is True False False True
All unary operators, such as the ! operator, evaluate expressions as follows:
The operator is applied to the resulting number.
For the ! operator, if expression is nonzero, result is zero. If expression is zero, result is 1.
AttributionsMicrosoft Developer Network: Article
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4