1) What will be the output of the following Python code?
def fn(var1):
var1.pop(1)
var1=[1,2,3]
fn(var1)
print(var1)
Technical Training III_B
Quiz
•
Science
•
1st Grade
•
Hard
Dev Kiran
Used 1+ times
FREE Resource
30 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
1) What will be the output of the following Python code?
def fn(var1):
var1.pop(1)
var1=[1,2,3]
fn(var1)
print(var1)
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
1) What will be the output of the following Python code?
def fn(var1):
var1.append(4)
var1=[1,2,3]
fn(var1)
print(var1)
[1, 2, 3, 4]
[1, 2, 3]
[1, 2, 4]
[1, 3, 4]
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
2) What is the output of the following Python code?
def func(a, b):
return a * b
result = func(3, 4)
print(result)
12
7
34
None
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
3) What will be the output of the following Python code?
def square(x):
return x ** 2
result = square(5)
print(result)
10
25
5
15
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following function convert an integer to an Unicode character in python?
ord(x)
unichr(x)
hex(x)
char()
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
'A' + 'B' if '12'.isdigit() else 'X' + 'Y'
A+B
X+Y
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is correctly evaluated for this function?
pow(x,y,z)
30 questions
SAINS TING.2 BAB 7 : KEELEKTRIKAN DAN KEMAGNETAN
Quiz
•
1st - 2nd Grade
26 questions
untitled
Quiz
•
1st Grade - University
25 questions
月相和星座
Quiz
•
1st - 12th Grade
26 questions
3ème énergie et puissance électrique
Quiz
•
1st Grade
30 questions
Python Quiz - Data type, If/Else, Coding
Quiz
•
1st - 5th Grade
27 questions
العالم الصغير 2
Quiz
•
1st Grade
30 questions
Öffnungszeiten
Quiz
•
1st - 2nd Grade
26 questions
qwertyzxcvbnm
Quiz
•
1st Grade
25 questions
Equations of Circles
Quiz
•
10th - 11th Grade
30 questions
Week 5 Memory Builder 1 (Multiplication and Division Facts)
Quiz
•
9th Grade
33 questions
Unit 3 Summative - Summer School: Immune System
Quiz
•
10th Grade
10 questions
Writing and Identifying Ratios Practice
Quiz
•
5th - 6th Grade
36 questions
Prime and Composite Numbers
Quiz
•
5th Grade
14 questions
Exterior and Interior angles of Polygons
Quiz
•
8th Grade
37 questions
Camp Re-cap Week 1 (no regression)
Quiz
•
9th - 12th Grade
46 questions
Biology Semester 1 Review
Quiz
•
10th Grade