Unary operators in C++
1. Unary Plus (+)
This operator specifies that a number is positive. It is optional to put this operator before a number as a number without sign is considered positive automatically.
Example: +14, 45
2. Unary Minus (-)
This operator makes a number negative.
Example: -1, -455
3. Pointer Operator (*)
This operator can be used to declare a pointer variable .
**Above Example declares a pointer variable p .
4. Address operator(&)
This operators basically refer to location of a variable in memory.
int n=20,*p; p=&n
**Above example assigns the address of variable n into pointer variable p.
Popular Books of Computer Science