Class 11 Computer Science Chapter 2 Introduction To Python Quiz 53 (25 MCQs)

Quiz Instructions

Select an option to see the correct answer instantly.

1. "and, or and not" are .....
2. Extension file in python is
3. What data type is used to represent text in Python?
4. Which of these is a valid variable name?
5. What method in Python is used to add an element to the end of a list?
6. Write the output of the following code:x=2; x=5; x=x+x; print(x)
7. Why is it important for students like Sebastian, Anaya, and Ella to learn computer science in school?
8. Which of the following tasks should a program perform based on the given requirements? (a) Generate a Fibonacci sequence of length N. (b) Calculate factorial and binomial coefficient using N and R.
9. What does print('a' in 'cat') output?
10. What is the output of the following code? print( 100/5)
11. What is the name of the Python environment that allows you to write your program and then test them out?
12. In a flowchart, parallelogram is used to represent .....
13. What is the output of the following code?x = 3while x > 0:x-= 1print(x)
14. Which of the following is a valid Python data type?
15. What is the output of print('Age:', age) if age = 25?
16. Which one of these is floor division?
17. How do you print "Hello, World!" in Python?
18. What is the result of the following expression:$4 * (2 + 3)$
19. Python is known as .....
20. How do you create a variable with the floating number 2.8?
21. What is the role of a Python interpreter?
22. What will the following code output if the user inputs "Alice" ? 'name = input("Enter your name: ")' 'print("Hello '' + name)'
23. Which of the following correctly accesses value 85 from a dictionary d = \{"marks":85\}?
24. How can you handle errors in Python?
25. What is the purpose of indentation in Python?