0% found this document useful (0 votes)
61 views1 page

Operators AND EXPRESSIONS

C language supports different types of operators that can be used to form expressions, including arithmetic, relational, equality, logical, unary, conditional, bitwise, assignment, comma, and size of operators. The document proceeds to discuss arithmetic operators, providing an example of declaring integer variables a, b, and result and using them to demonstrate arithmetic operator syntax. It then defines relational operators as those that compare two values or expressions and return a true or false value depending on whether the conditional relationship holds or not.

Uploaded by

mahmoud
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
61 views1 page

Operators AND EXPRESSIONS

C language supports different types of operators that can be used to form expressions, including arithmetic, relational, equality, logical, unary, conditional, bitwise, assignment, comma, and size of operators. The document proceeds to discuss arithmetic operators, providing an example of declaring integer variables a, b, and result and using them to demonstrate arithmetic operator syntax. It then defines relational operators as those that compare two values or expressions and return a true or false value depending on whether the conditional relationship holds or not.

Uploaded by

mahmoud
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

Operators AND EXPRESSIONS:-

 C language supports different types of operators, which can be used with variables and constants
 To form expressions. These operators can be categorized into the following major groups:
 Σ Arithmetic operators Σ Relational operators
 Σ Equality operators Σ Logical operators
 Σ Unary operators Σ Conditional operator
 Σ Bitwise operators Σ Assignment operators
 Σ Comma operator Σ Size of operator
 We will now discuss all these

Arithmetic Operators
Consider three variables declared as,
int a=9, b=3, result;
We will use these variables to explain arithmetic operators. Table 1.7 shows the arithmetic operators,
Their syntax, and usage in C language.

Relational Operators
A relational operator, also known as a comparison operator, is an operator that compares two
Values or expressions. Relational operators return true or false value, depending on whether the
Conditional relationship between the two
Operands holds or not.

You might also like