Computer Science, asked by kaurayana, 16 days ago

Write a program in java to find the result of the following expressions.(Assume a=20,b=30) i) a%b ii)a/=b iii)(a+b*100)/10iv)a++​

Answers

Answered by r27272278
5

\huge\fcolorbox {magenta} {violet} {Hey mate here is the answer}

class s01_02

{

public static void main(String args[])

{

int a=20,b=30;

System.out.println(" i) (a<<2)+(b>>2): "+(a<<2)+(b>>2) );

System.out.println(" ii) (a)||(b>0) : "+(a)||(b>0) );

System.out.println("iii) (a+b*100)/10 : "+(a+b*100)/10 );

System.out.println(" iv) (a&b) : "+(a&b) );

}

}

\huge\fcolorbox {magenta} {violet} {Thank you}

Similar questions