Search the courses, subjects, tracks, games and features, or jump straight to a page.
4 cards from this section. Quick, good the night before a test.
What is a method?
Think about tasks completed in programming.
What do we call the values passed to methods?
They are part of the method declaration.
What is the primary purpose of a method?
Consider what tasks methods are designed for.
True or False: Methods can return values in Java.
Think about examples where outputs result from method calls.
Design a method that calculates the factorial of a number. Explain how this method uses recursion.
Consider how recursion helps break the problem into smaller instances.
Create a program that uses methods to find the maximum number in an array. Discuss how you would manage multiple method calls.
Think about how you'll loop through an array to find the maximum value.
5 more questions in this section. Enroll free to practise them all.
Enroll free