Functions - Programming 1 Fawaz

Quiz
•
Computers, Education
•
10th Grade
•
Hard
Standards-aligned
Mahi Mukati
FREE Resource
19 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the output of the following piece of code?
def test(i,j):
if(i==0):
return j
else:
return test(i-1,i+j)
print(test(4,7))
13
7
Infinite Loop
17
2.
MULTIPLE SELECT QUESTION
30 sec • 1 pt
Which of the following function calls can be used to invoke the below function definition?
def test(a,b,c,d)
test(1,2,3,4)
test(a=1,2,3,4)
test(a=1,b=2,c=3,4)
test(a=1,b=2,c=3,d=4)
3.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Pick one from the following statements to correctly complete the function body to get the output 5 in the given code snippet:
def f(number):
#missing function body
print(f(5))
return "number"
print(number)
print("number")
return number
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
what is a variable defined inside all the function referred to as?
A static variable
A global variable
A local variable
An automatic variable
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
what is a variable defined outside all the function referred to as?
A static variable
A global variable
A local variable
An automatic variable
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Create a free account and access millions of resources
Similar Resources on Wayground
20 questions
Int Prog: Lists and Functions

Quiz
•
9th - 12th Grade
20 questions
Mastering Python Loops and Functions

Quiz
•
10th Grade - University
20 questions
Python Basics & Syntax

Quiz
•
10th - 12th Grade
16 questions
Python programming

Quiz
•
6th - 12th Grade
20 questions
Python Programming Quiz

Quiz
•
9th Grade - University
15 questions
Python Basics Quiz

Quiz
•
6th - 10th Grade
15 questions
Functions in Python

Quiz
•
9th - 12th Grade
20 questions
Python - Iteration (For Loops)

Quiz
•
10th Grade
Popular Resources on Wayground
18 questions
Writing Launch Day 1

Lesson
•
3rd Grade
11 questions
Hallway & Bathroom Expectations

Quiz
•
6th - 8th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
40 questions
Algebra Review Topics

Quiz
•
9th - 12th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
19 questions
Handbook Overview

Lesson
•
9th - 12th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
Discover more resources for Computers
40 questions
Algebra Review Topics

Quiz
•
9th - 12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
19 questions
Handbook Overview

Lesson
•
9th - 12th Grade
10 questions
Characteristics of Life

Quiz
•
9th - 10th Grade
10 questions
Essential Lab Safety Practices

Interactive video
•
6th - 10th Grade
62 questions
Spanish Speaking Countries, Capitals, and Locations

Quiz
•
9th - 12th Grade
20 questions
First Day of School

Quiz
•
6th - 12th Grade
21 questions
Arithmetic Sequences

Quiz
•
9th - 12th Grade