NEW
Font size
WorksheetsPython_Quiz_1
Total questions: 10
Worksheet time: 10mins
What will be the output of the following Python code?
[‘ab’, ‘cd’]
[‘AB’, ‘CD’]
[None, None]
none of the mentioned
What will be the output of the following Python code?
1 2
1 2 3
error
none of the mentioned
What will be the output of the following Python code?
a b c d e f
abcdef
i i i i i i …
error
What will be the output of the following Python code?
no output
i i i i i i …
a a a a a a …
a b c d e f
What will be the output of the following Python code?
0 1 2 3 4 Here
0 1 2 3 4 5 Here
0 1 2 3 4
1 2 3 4 5
What will be the output of the following Python code?
0 1 2
error
0 1 2 0 1 2
none of the mentioned
Suppose list1 is [4, 2, 2, 4, 5, 2, 1, 0], Which of the following is correct syntax for slicing operation?
print(list1[2:])
print(list1[:2])
print(list1[:-2])
all of the mentioned
What will be the output of the following Python statement?
a
ab
cd
dc
Suppose listExample is [3, 4, 5, 20, 5, 25, 1, 3], what is list1 after listExample.extend([34, 5])?
[3, 4, 5, 20, 5, 25, 1, 3, 34, 5]
[1, 3, 3, 4, 5, 5, 20, 25, 34, 5]
[25, 20, 5, 5, 4, 3, 3, 1, 34, 5]
[1, 3, 4, 5, 20, 5, 25, 3, 34, 5]
What will be the output of the following Python code?
2 3 4 5 6 1
6 1 2 3 4 5
2 3 4 5 6 6
1 1 2 3 4 5
