Operators

Q1:
What will be the output of the C#.NET code snippet given below?
byte b1 = 0xAB;
byte b2 = 0x99;
byte temp;
temp = (byte)~b2;
Console.Write(temp + ' ');
temp = (byte)(b1 << b2);
Console.Write (temp + ' ');
temp = (byte) (b2 >> 2);
Console.WriteLine(temp);

A 102 1 38

B 108 0 32

C 102 0 38

D 1 0 1

ANS:A - 102 1 38

No answer description is available. Let's discuss.



img not found
img

For help Students Orientation
Mcqs Questions

One stop destination for examination, preparation, recruitment, and more. Specially designed online test to solve all your preparation worries. Go wherever you want to and practice whenever you want, using the online test platform.