In this blog |
---|
types of operator |
types of operator
there are 3 types of opearator
urnay operator
operator that work on only 1 operand
eg : ++a // a is variable of any valid type
type of unary operator...
- unary minus(-)
- increment(++)
- decrement(- -)
- logical NOT(!) and bitwise NOT(~)
- Addressof operator(&) and Indircetion ( * )
- sizeof()
binary operator
operator that work on 2 operand
eg: a+b //a and b are of any valid type
types of binary operator...
1. arithmethic
2. relational
3. equality
4. logical
5. bitwise
6. assignment
ternary operator
operator that work on 3 operand
eg: (a>b)?a:b
types of ternary operator...
1. (expression)?(expression):(expression)
(leave the comment down below if you have a doubt or suggestions ,thnks🙂)
No comments:
Post a Comment