Functions Test

Functions Test

9th - 12th Grade

20 Qs

quiz-placeholder

Similar activities

P5.js Variables and Conditional Statements

P5.js Variables and Conditional Statements

9th - 12th Grade

15 Qs

P5.js Conditional Statements in Computer Science

P5.js Conditional Statements in Computer Science

9th - 12th Grade

15 Qs

Functions Parameters Return

Functions Parameters Return

9th - 12th Grade

20 Qs

JavaScript Functions and Parameters

JavaScript Functions and Parameters

9th - 12th Grade

20 Qs

JavaScript and Graphics

JavaScript and Graphics

9th - 12th Grade

15 Qs

IST CodeHS Unit 8 JavaScript Review

IST CodeHS Unit 8 JavaScript Review

9th - 12th Grade

22 Qs

CSA Lessons 1 - 4

CSA Lessons 1 - 4

10th - 12th Grade

15 Qs

Java Math

Java Math

9th - 12th Grade

15 Qs

Functions Test

Functions Test

Assessment

Quiz

Computers

9th - 12th Grade

Hard

Created by

Barbara White

FREE Resource

20 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is an argument?

A variable passed as a value to a function

A variable passed in from outside the function

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is an parameter?

A variable passed as a value to a function

A variable passed in from outside the function

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the parameter of this

function quadrupleNumber(x){

var quadX = 4 * x;

println(quadX);

}

x

println

quadX

none

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Why do we write functions?

Make our code easier to understand by giving a readable name to a group of instructions

Avoid writing repeated code

Make our code reusable

All of the above

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

It is very important to pass parameters to functions in the proper order

True

False

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What are the parameters of the printNumbers function?

function printNumbers(first, second, third){

println(first);

println(second);

println(third);

}

first, second, third

x, y, z

println

rintNumbers

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which statement allows us to return values from functions?

break

if

return

function

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?