
Python Functions and Data Structures Quiz

Quiz
•
Other
•
University
•
Medium
EC M
Used 1+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the purpose of the 'greet' function in Python?
To greet a person
To add two numbers
To create a list
To install a package
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which command is used to install packages in Python?
pip install
setup
import
install
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the 'add' function return when called with arguments 5 and 3?
3
15
5
8
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a valid way to create a DataFrame using Pandas?
df = DataFrame.create(data)
df = new DataFrame(data)
df = create.DataFrame(data)
df = pd.DataFrame(data)
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will the command 'greet()' output if no name is provided?
Hello, Guest!
Hello, Alice!
Hello, Charlie!
Hello, Bob!
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which data structure is used to represent a matrix in Python?
DataFrame
Numpy array
Array
List
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of 'print(df[df["Age"]>30])' given the DataFrame?
All people
People younger than 30
People older than 30
No one
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
Numpy and Pandas Quiz

Quiz
•
University
10 questions
Python for Data Anlaysis Quiz- 7

Quiz
•
University
10 questions
PLACEMENT TEST DATA LITERATURE

Quiz
•
University
12 questions
Database NoSQL (MongoDB)

Quiz
•
University - Professi...
9 questions
Python Review Module 15 - Plotting

Quiz
•
University
10 questions
Statistics for Psychology - Quiz 2

Quiz
•
University
14 questions
OS MINT 22

Quiz
•
University
10 questions
Python for Data Analysis Quiz 10

Quiz
•
University
Popular Resources on Wayground
50 questions
Trivia 7/25

Quiz
•
12th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
11 questions
Negative Exponents

Quiz
•
7th - 8th Grade
12 questions
Exponent Expressions

Quiz
•
6th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
20 questions
One Step Equations All Operations

Quiz
•
6th - 7th Grade
18 questions
"A Quilt of a Country"

Quiz
•
9th Grade