class assignops
{
public static void main (String arg[])
{
int a=10,b=25,c=5,d=18,e=49;
a+=10;
b-=10;
c*=10;
d/=2;
e%=7;
System.out.println ("\n\t a = "+a);
System.out.println ("\n\t b = "+b);
System.out.println ("\n\t c = "+c);
System.out.println ("\n\t d = "+d);
System.out.println ("\n\t e = "+e);
}
}
Note:
After execution you will observe following five changes- Value of 'a' is increased by 10
- Value of 'b' is decreased by 10
- Value of 'c' is 50 (due to multiplying by 10)
- Value of 'd' is 9 (because we are dividing 'c' by 2)
- Value of 'e' is 0 (because 7 divides 49 properly)
No comments:
Post a Comment