Python Quiz Questions Part-1
FREE Online Courses: Click for Success, Learn for Free - Start Now!
Quiz Summary
0 of 30 Questions completed
Questions:
Information
You have already completed the quiz before. Hence you can not start it again.
Quiz is loading…
You must sign in or sign up to start the quiz.
You must first complete the following:
Results
Results
0 of 30 Questions answered correctly
Your time:
Time has elapsed
You have reached 0 of 0 point(s), (0)
Earned Point(s): 0 of 0, (0)
0 Essay(s) Pending (Possible Point(s): 0)
Categories
- Not categorized 0%
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
- Current
- Review / Skip
- Answered
- Correct
- Incorrect
-
Question 1 of 30
1. Question
Which of the following is true about Python?
CorrectIncorrect -
Question 2 of 30
2. Question
Which of the following is not true about identifiers in Python?
CorrectIncorrect -
Question 3 of 30
3. Question
Difference between list and tuples in Python?
CorrectIncorrect -
Question 4 of 30
4. Question
Which of the following is not a data type in Python?
CorrectIncorrect -
Question 5 of 30
5. Question
Which of the following has a higher precedence?
CorrectIncorrect -
Question 6 of 30
6. Question
Which of the following is not a namespace in Python?
CorrectIncorrect -
Question 7 of 30
7. Question
Which of the following methods is used to jumble the elements of a list randomly?
CorrectIncorrect -
Question 8 of 30
8. Question
Which of the following is not loop controls in Python?Which of the following is not loop controls in Python?
CorrectIncorrect -
Question 9 of 30
9. Question
Which of the following cannot be used to implement a switch in Python?
CorrectIncorrect -
Question 10 of 30
10. Question
Which of the following is not a data structure that is derived from dictionaries?
CorrectIncorrect -
Question 11 of 30
11. Question
-
- Find the output of the below code.
3*4**2
CorrectIncorrect -
-
Question 12 of 30
12. Question
Which of the following gives an error?
CorrectIncorrect -
Question 13 of 30
13. Question
- What is the output of the below code?
string = “\t\t\t\n\n\nPythonGeeks\n\n\n\t\t\t”
string.strip()
CorrectIncorrect -
Question 14 of 30
14. Question
- Find the output of the below code.
seq1=(1,2,3,4,5,6,7,8,9,10)
seq1[-1::-2]
CorrectIncorrect -
Question 15 of 30
15. Question
- What is the output of the following code?
print(467.34e-2)
CorrectIncorrect -
Question 16 of 30
16. Question
- Which of the following gives an error for the dictionary below?
dict1={1:’one’,2:’two’,3:’three’,4:’four’}
CorrectIncorrect -
Question 17 of 30
17. Question
- What is the output of the below code?
type({})
CorrectIncorrect -
Question 18 of 30
18. Question
Which of the following is the correct way to use filter function?
CorrectIncorrect -
Question 19 of 30
19. Question
- Find the output of the code.
def func(a):
print(a**2)
fund(4)
CorrectIncorrect -
Question 20 of 30
20. Question
Which of the following gives an error?
CorrectIncorrect -
Question 21 of 30
21. Question
- Find the output of the below code?
“,”.join([’12’,’34’,’56’])
CorrectIncorrect -
Question 22 of 30
22. Question
- What is the output of the below code?
var=3
def func1():
var=4
def func2():
global var
var=10
func2()
print(var)
func1()
CorrectIncorrect -
Question 23 of 30
23. Question
- Find the output of the below code.
3*(4+3)>9*(3/2)
CorrectIncorrect -
Question 24 of 30
24. Question
- Which of the following is the correct way to print the following statement
“His name is abc and he loves Python”
If name =’abc’ and lang=’Python’?
CorrectIncorrect -
Question 25 of 30
25. Question
- What is the output of the below code?
seq=[‘a’,’b’,’f’,’i’]
seq.extend([1,2])
seq
CorrectIncorrect -
Question 26 of 30
26. Question
- Find the output of the below code.
seq1={1,2,3,2,4}
seq2={3,9,0}
seq1.update(seq2)
len(seq1)
CorrectIncorrect -
Question 27 of 30
27. Question
- What is the output of the below code?
from collections import defaultdict
dDic=defaultdict(lambda:0)
dDic[1]=3
dDic[4]=5
dDic[2]
CorrectIncorrect -
Question 28 of 30
28. Question
Which of the following give the output as 12345?
CorrectIncorrect -
Question 29 of 30
29. Question
- Find the output of the below code?
a=6
if(a>=6):
print(a-1,end=’ ‘)
elif (a<=6):
print(a,end=”)
CorrectIncorrect -
Question 30 of 30
30. Question
- What is the output of the below code?
a=5
while(a>0):
if(a/2==1):
break;
print(a,end=”)
a=a-2
else: print(‘end’)
CorrectIncorrect