Python Programming: Functions and Procedures

Python Programming: Functions and Procedures

Assessment

Quiz

Computers

9th - 11th Grade

Hard

Used 11+ times

FREE Resource

Student preview

quiz-placeholder

12 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following describes a Local Variable

They can be used throughout the whole program

They are only available to be used in the function where they are defined

They are easier to access

They change during whenever they are used.

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What term is used to describe data passed into/out of a function?

Variable

Loop

Constant

Parameter

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

If the main code is to use information from a function, what is required?

print statement

variables

constants

return statement

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Joe wants to create a subroutine that will roll a dice. Which syntax is correct?

def dice roll ():

def diceroll ()

def diceroll ():

def diceroll []:

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is missing from this code for it to print first name and surname?

print

input

return (name)

print(name)

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

Why would this program report an error?

message is not passed into the function as a parameter

message is not defined

Hello World is not valid

There is no return on the function

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is missing from this program for this function to print Hello, world?

Nothing

Call of the function

Parameters

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?