Tag: operators

62 votes
14 answers
654 views
Is < faster than <=?

Is if (a < 901) faster than if (a <= 900)? Not exactly as in this simple example, but there are slight p

avatar
Trudy
0 1 0 9
asked 07 September, 2021
66 votes
16 answers
2.8K views
What is the difference between &apos;/&apos; and &apos;//&apos; when used for division?

Is there a benefit to using one over the other? In Python 2, they both seem to return the same results: >&

avatar
Thurman
0 1 0 9
asked 07 September, 2021
66 votes
7 answers
2.3K views
What&apos;s the difference between & and && in MATLAB?

What is the difference between the & and && logical operators in MATLAB?

avatar
Jefferey
0 1 0 9
asked 07 September, 2021
55 votes
6 answers
375 views
Is there a VB.NET equivalent for C#&apos;s &apos;??&apos; operator?

Is there a VB.NET equivalent for C#'s ?? operator?

avatar
Winford
0 1 0 9
asked 07 September, 2021
58 votes
4 answers
1.5K views
Is there a conditional ternary operator in VB.NET?

In Perl (and other languages) a conditional ternary operator can be expressed like this: my $foo = $bar == $b

avatar
Lynette
0 1 0 9
asked 07 September, 2021
54 votes
27 answers
1.6K views
Does Python have a ternary conditional operator?

If Python does not have a ternary conditional operator, is it possible to simulate one using other language co

avatar
Mikki
0 1 0 9
asked 07 September, 2021
64 votes
11 answers
977 views
Why don&apos;t Java&apos;s +=, -=, *=, /= compound assignment operators require casting?

Until today, I thought that for example: i += j; Was just a shortcut for: i = i + j; But if we try this:

avatar
Jeff
0 1 0 9
asked 07 September, 2021
61 votes
30 answers
1.9K views
What is the !! (not not) operator in JavaScript?

I saw some code that seems to use an operator I don't recognize, in the form of two exclamation points, l

avatar
Adolfo
0 1 0 9
asked 07 September, 2021
62 votes
21 answers
2.2K views
Reference — What does this symbol mean in PHP?

What is this? This is a collection of questions that come up every now and then about syntax in PHP. This is a

avatar
Lynette
0 1 0 9
asked 07 September, 2021