Home / Programming MCQs / JAVA MCQs / Question

R

Ram Sharma • 170K Points
Coach

Q. What is the output of Java Program with Shift Right Fill Zeroes operator?

Code:
byte num = (byte)0b000_1000;
System.out.print(num + ",");
num = (byte)(num >>> 1);
System.out.print(num);
(A) -8, 4
(B) 8, 4
(C) 8, -4
(D) -8, -4

No solution found for this question.
Add Solution and get +2 points.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.