A
Q. What is the output of the following code?
Code:
public static void myMethod(int x) {
System.out.println(x * 2);
}
myMethod(5);
System.out.println(x * 2);
}
myMethod(5);
- Correct Answer - Option(A)
- Views: 24
- Filed under category Java
- Hashtags:
Discusssion
Login to discuss.