A
Q. What will be the output of the following Java program?
Code:
class rightshift_operator
{
public static void main(String args[])
{
int x;
x = 10;
x = x >> 1;
System.out.println(x);
}
}
{
public static void main(String args[])
{
int x;
x = 10;
x = x >> 1;
System.out.println(x);
}
}
- Correct Answer - Option(B)
- Views: 18
- Filed under category Java
- Hashtags:
Discusssion
Login to discuss.