Toggle Navigation
Games
Blog
Class PIN
Join for Free
Sign in
Toggle Navigation
Games
PIN
Join for Free
Blog
Pricing
Contact us
Help center
Sign in
Study
PR1-W5-Part1-Switch, String Operations & Static ...
0
%
0
0
0
Back
Restart
18. In the context of overloading, which Java method is overloaded in the Math class? (5)
D
Oops!
Okay!
15. What is the key reason for using variables to hold intermediate values during incremental development? (4)
B
Oops!
Okay!
9. If no access specifier is provided for a method, where can it be called from? (5)
B
Oops!
Okay!
4. Which of the following modifiers is used to specify that a subroutine belongs to the class, rather than to instances of the class? (3)
B
Oops!
Okay!
19. What should be avoided when overloading methods in Java? (4)
C
Oops!
Okay!
14. What is the main benefit of incremental development? (3)
C
Oops!
Okay!
5. What is the role of the parameter-list in a method definition? (2)
B
Oops!
Okay!
12. What is the role of parentheses in a subroutine call, even if the subroutine has no parameters? (2)
B
Oops!
Okay!
8. In the method signature public static void main(String[] args), what does String[] args represent? (4)
C
Oops!
Okay!
11. What happens when you define a subroutine in a class? (2)
B
Oops!
Okay!
13. If you need to call a static method playGame() from a class named Poker, which of the following is the correct syntax? (3)
B
Oops!
Okay!
17. Why is the calculateArea() method not considered recursive? (4)
B
Oops!
Okay!
21. What does the expression !isSingleDigit(17) evaluate to? (3)
A
Oops!
Okay!
16. What should be done after the program is confirmed to be working during incremental development? (3)
B
Oops!
Okay!
10. Which of the following method signatures is invalid? (3)
D
Oops!
Okay!
7. Which of the following statements is false regarding parameters in a subroutine? (3)
A
Oops!
Okay!
22. Which of the following is a correct invocation of the isSingleDigit method? (2)
B
Oops!
Okay!
3. What happens if two methods in a class have the same name and the same parameter list? (4)
A
Oops!
Okay!
20. What does the second version of calculateArea method accept as parameters? (3)
C
Oops!
Okay!
2. By conventions, what is the correct way to define a method in Java? (2)
C
Oops!
Okay!
Won 5 points
5
Oops!
Okay!
Won 25 points
25
Oops!
Okay!
6. Consider the method declaration public void changeChannel(int channelNum). What does the int channelNum represent? (2)
C
Oops!
Okay!
1. What is a method in Java? (1)
B
Oops!
Okay!
Your experience on this site will be improved by allowing cookies.
Allow cookies