
MTA 98-381 Quiz
Authored by John Khoury
Other
8th Grade
Used 1+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is Python?
Python is a database management system used for storing and retrieving data.
Python is a markup language used for creating web pages.
Python is a high-level programming language known for its simplicity and readability.
Python is a low-level programming language used for system programming.
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a data type in Python?
int
str
list
bool
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct syntax for error handling in Python?
try: except ExceptionType:
try: except:
try: except ErrorType:
try: # code that may raise an exception except ExceptionType: # code to handle the exception
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code? x = 5 y = '10' print(x + y)
510
TypeError
TypeError: unsupported operand type(s) for +: 'int' and 'str'
SyntaxError: invalid syntax
15
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is not a valid data type in Python?
string
boolean
integer
character
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct way to handle an exception in Python?
Using if-else statements.
Using for loops.
Using switch statements.
Using try-except blocks
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code? x = 'Hello' print(x[2:])
llo
lo
ell
llo
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?