What will be returned from the following method?
Public static int methodA()
{
Double a = 8.5 + 9.5;
Return a;
}
A) 18.0
B) 18 (as an integer)
C) 8.0
D) This is an error.
Correct Answer:
Verified
Q7: Methods are commonly used to break a
Q8: In the method header the static method
Q11: A parameter variable's scope is the method
Q12: Constants, variables, and the values of expressions
Q13: The expression in a return statement can
Q15: No statement outside the method in which
Q17: In the method header, the method modifier
Q48: The process of breaking a problem down
Q51: Local variables can be initialized with:
A) constants
B)
Q54: A value-returning method must specify this as
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents