Expression of the C # tutorial [original]

Source: Internet
Author: User

The variables, data types, and type security are described earlier. We can see that the value assignment operator "=" is used ". In fact, C # also contains many operators for such processing.

By combining variables and literal values (which are called operands when operators are used) with operators, you can create an expression, which is the basic block for computing.

 

The range of operators is very extensive, simple, and complex. Some of them may only be used in mathematics.Program. Simple operations include all basic mathematical operations. For example, the + operator adds two operands together, while complex operations include processing them through the binary representation of the variable content. There are also logical operators used to process boolean values and value assignment operators, such as = operators.

 

Next we will first introduce the mathematical and value assignment operators, and the logical operators will be integrated in the Process Control Section, because the logical operators mainly discuss the Boolean logic of the control program flow.

 

Operators are roughly divided into the following three types:

 

● Unary operator, processing an operand

 

● Binary operator, processing two operands

 

● Ternary operator, processing three operands

 

Most operators are binary operators, with only a few unary operators and a ternary operator. The following describes mathematical operators, including unary operators and binary operators.

 

This article is a new one. For more information, see the source and author!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.