Friday, July 29, 2016

C Basics - Overview of Operators in C

An operator in general, is a symbol that operates on a certain data type. An operator tells the compiler to perform specific mathematical or logical functions. C language is very rich in operators.

Operators are symbols (both single characters and character combinations) that specify how values are to be manipulated. Each symbol is interpreted as a single unit, called a token.

C operators can be classified into following types,
Arithmetic operators = + - * / % ++ --
Relation operators == != > < >= <=
Logical operators && || !
Bitwise operators & | ^ ~ << >>
Compound Assignment operators += -+ *= /= %= &= |= ^= <<= >>=
Conditional operator ? :
Miscellaneous operators sizeof & * , (type) () [] -> .



Related topics:
Arithmetic Operators in C   |   Relational Operators in C   |   Logical Operators in C   |   Bitwise Operators in C   |   Compound Assignment Operators in C   |   Conditional Operators in C   |   Miscellaneous Operators in C   |   Operator Precedence and Associativity in C

List of topics: C Programming

No comments:

Post a Comment