Operators +, -, *, /, ++, --, etc.
Separators all symbols that divide everything are called separators. Example: {}, [], comma, dot, (), etc.
Unary Operators
Increment Operator (Post)
Int no = 5;
System.out.println(no++);
Output = 5.
Decrement Operator (Post)
System.out.println(no--);
Output = 5.
Pre-increment operator
Int no = 5;
System.out.println(++no);
Output = 6.
Pre-decrement operator
System.out.println(--no);
Output = 4.
Pre-increment operator
Int no = 5;
System.out.println(++no);
Output = 6.
Pre-decrement operator
System.out.println(--no);
Output = 4.
Top comments (0)