
PROGRAMMING CONCEPTS

Quiz
•
Computers
•
12th Grade
•
Medium
JOHN ZARATE
Used 2+ times
FREE Resource
29 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
What is the correct syntax to declare a variable in Python?
variable x = 5
int x = 5;
x = 5
declare x = 5
Answer explanation
declaring variable in python, don't need to have data type and semi colon ";"
2.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
Which data type is mutable in Python?
Tuple
String
List
Integer
Answer explanation
This means we can change an item in a list by accessing it directly as part of the assignment statement
3.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
What does the elif statement do in Python?
Ends the program
Runs a loop
Checks another condition if the previous one is false
Defines a function
4.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
What will print(3 * "hello") output?
hellohellohello
hello * 3
A storage location for data
error
Answer explanation
n Python, the * operator can be used with strings to repeat them a specified number of times.
3 * "hello" means "hello" is repeated 3 times.
So, "hello" * 3 evaluates to "hellohellohello" (without spaces).
5.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
What is debugging?
Removing unnecessary comments from code
Fixing errors in a program
Writing new code
Running a program without stopping
6.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
Which of the following is a valid way to access an element in a list?
list[1]
list(1)
list{1}
list.1
Answer explanation
In Python, elements in a list are accessed using indexing with square brackets ([]).
7.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
The "if" statement is used for looping.
REYAL
FAKEY
Create a free account and access millions of resources
Similar Resources on Wayground
26 questions
The First Programming Languages

Quiz
•
9th - 12th Grade
25 questions
CSP Unit 6 Review

Quiz
•
12th Grade
25 questions
AQA OOP Programming

Quiz
•
10th - 12th Grade
27 questions
Python Fundamentals - II

Quiz
•
11th - 12th Grade
25 questions
Visual Programming

Quiz
•
5th - 12th Grade
25 questions
Basics of Python

Quiz
•
9th - 12th Grade
31 questions
JavaScriptjQuery-00-JS-Introduction[F]

Quiz
•
9th - 12th Grade
25 questions
HTML

Quiz
•
9th - 12th Grade
Popular Resources on Wayground
10 questions
Video Games

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

Interactive video
•
6th - 10th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
10 questions
UPDATED FOREST Kindness 9-22

Lesson
•
9th - 12th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
20 questions
US Constitution Quiz

Quiz
•
11th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade