
PYTHON REVISION TOUR
Authored by Geethanjali BK
Computers
12th Grade
Used 2+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
22 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the following statement:
print(3-2**2**3+99/11)
a. 244
b. 244.0
-244.0
d. Error
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of the following will delete key-value pair for key = “Red” from a dictionary D1?
a. delete D1("Red")
b. del D1["Red"]
c. del.D1["Red"]
d. D1.del["Red"]
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of the following statement(s) would give an error during execution of the following code?
tup = (20,30,40,50,80,79)
print(tup) #Statement 1
print(tup[3]+50) #Statement 2
print(max(tup)) #Statement 3
tup[4]=80 #Statement 4
a. Statement 1
b. Statement 2
c. Statement 3
d. Statement 4
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Assertion(A): List is an immutable data type
Reasoning(R): When an attempt is made to update the value of an immutable variable, the old variable is destroyed and a new variable is created by the same name in memory.
(a) Both A and R are true and R is the correct explanation for A
(b)Both A and R are true and R is not the correct explanation for A
(c) A is True but R is False
(d)A is false but R is True
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is an invalid datatype in Python?
(a) Set
(b) None
(c)Integer
(d)Real
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Given the following dictionaries
dict_exam={"Exam":"AISSCE", "Year":2023}
dict_result={"Total":500, "Pass_Marks":165}
Which statement will merge the contents of both dictionaries?
a. dict_exam.update (dict_result)
b. dict_exam + dict_result
c. dict_exam.add (dict_result)
d. dict_exam.merge (dict_result)
7.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
Consider the given expression: not True and False or True
Which of the following will be correct output if the given expression is evaluated?
(a) True
(b) False
(c) NONE
(d) NULL
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?