Using Operators in C# Operators Expressions in C# comprise of one or more operators that performs some operations on variables. An operation is an action performed on single or multiple values stored in variables in order to modify them or to generate a new value. Therefore, an operation takes place with the help of minimum one symbol and a value. The symbol is called an operator and it determines the type of action to be performed on the value. The value on which the operation is to be performed is called an operand. An operand might be a complex expression. For example, (X * Y) + (X – Y) is a complex expression, where the + operator is used to join two operands. Types of Operators Operators are used to simplify expressions. In C#, there is a predefined set of operators used to perform various types of operations. C# operators are classified into six categories based on the action they perform on values. These six categories of operators are as follows: Arithmetic Operat...
Comments
Post a Comment