// Increment Operator example
class IncrementOperatoeExample
{
public static void main( String args[ ] )
{
int a = 10, b = 20 ,c;
c = ( ++a ) + ( ++b );
// a++ is Post fix increment
// ++b is pre fix increment
System.out.println( " Value of a = " + a );
System.out.println( " Value of b = " + b );
System.out.println( " Value of c = " + c );
}
}
Output:Value of a = 11
Value of b = 21
Value of c = 32