
Group-B Python Quiz
Authored by Ronak Doshi
others
University
Used 11+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
7 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
5 sec • 1 pt
Which of the following is not a valid data type in Python?
int
float
char
str
2.
MULTIPLE CHOICE QUESTION
5 sec • 1 pt
What does the len() function in Python return?
The length of a string
The number of elements in a list or tuple
The number of keys in a dictionary
All of the mentioned
3.
MULTIPLE CHOICE QUESTION
5 sec • 1 pt
What does the append() method do when used with lists in Python?
Adds an element to the end of the list
Removes the last element of the list
Sorts the elements of the list
Reverses the order of elements in the list
4.
MULTIPLE CHOICE QUESTION
5 sec • 1 pt
Which of the following is the correct way to import the math module in Python?
import math
include math
use math
require math
5.
MULTIPLE CHOICE QUESTION
5 sec • 1 pt
What does the pop() method do when used with lists in Python?
Removes the first element of the list
Removes the last element of the list
Removes the element at the specified index
Adds an element to the end of the list
6.
MULTIPLE CHOICE QUESTION
5 sec • 1 pt
Which of the following function convert a string to a float in python?
long(x [,base] )
float(x)
str(x)
7.
MULTIPLE CHOICE QUESTION
5 sec • 1 pt
What data type is the object below ? L = [1, 23, ‘hello’, 1]
List
Dictionary
Tuple
Array
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?