Java Methods and Return Values

Java Methods and Return Values

10th - 12th Grade

11 Qs

quiz-placeholder

Similar activities

Programming Basics

Programming Basics

11th - 12th Grade

10 Qs

ข้อสอบ Java

ข้อสอบ Java

11th Grade

10 Qs

python quiz

python quiz

6th Grade - Professional Development

10 Qs

Java Programming Basics

Java Programming Basics

9th - 12th Grade

12 Qs

C++ Recursion

C++ Recursion

8th - 12th Grade

12 Qs

Java - arrays and String methods

Java - arrays and String methods

9th - 12th Grade

12 Qs

Project-Stem Unit 1 python coding

Project-Stem Unit 1 python coding

9th - 12th Grade

12 Qs

C# 14

C# 14

10th Grade

10 Qs

Java Methods and Return Values

Java Methods and Return Values

Assessment

Quiz

Computers

10th - 12th Grade

Medium

Created by

Courtney Yatteau

Used 36+ times

FREE Resource

11 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

these are the number and types of variables or objects sent to a method
parameters
arguments

2.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

Media Image
What is the returned value of recMethod(5)?
68
70
75
82

3.

MULTIPLE SELECT QUESTION

2 mins • 1 pt

Java method definitions require which of the following parts in their headers?

A method name

A set of parentheses

A comma-separated parameter list

A semi-colon

4.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

The body of a method definition is contained within a set of ______________.

parentheses

rectangle brackets

curly braces

angle brackets

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which method has a parameter and returns an integer?

public void methodExample(int num1, int num2) {...}

public void methodExample(int num) {...}

public int methodExample(int num) {...}

public int methodExample() {...}

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is stored in x after the code segment is executed?


int x;

x = 10 + 5 % 3;

0

5

11

12

7.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

If a method of a class is defined like this:
goDown();
what does the () mean?
It requires data to be passed in
It has no parameters
It can be called from BlueJ

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?