Introduction to C#
- slide 29 : 43
Expressions and Operators
Operator Precedence
Major differences between the two languages
Operator precedence in C#
VB operator precedence
Equality and Assignment
VB: Suffers from the choice of using the same operator symbol
=
for both equality and assignment
VB: The context determines the meaning of the operator symbol
=
C#: Separate equality operator
==
and assignment operator
=
Remarkable operators
VB:
Mod
,
&
,
\
,
And
,
AndAlso
,
Or
,
OrElse
C#:
==
,
!
,
%
,
?: