Python Quiz for Beginners. 0% 0 Oops! Time up! Python programming Python Basic Quiz This Quiz for beginners. You can enhance and check your knowledge in python after attending this quiz. Login Here. NameEmail 1 / 50 Category: Output Based Questions 1. print(10 == 10) a. True b. 10 c. False d. Error 2 / 50 Category: Output Based Questions 2. print(type("10")) a. float b. string c. int 3 / 50 Category: Output Based Questions 3. print(5 % 2) a. 2 b. Error c. 0 d. 1 4 / 50 Category: Output Based Questions 4. print(5 + 3) a. Error b. 53 c. None d. 8 5 / 50 Category: Output Based Questions 5. print("Python"[0]) a. Python b. P c. Error d. y 6 / 50 Category: Output Based Questions 6. a = [1,2,3] print(len(a)) a. 3 b. Error c. 2 d. 1 7 / 50 Category: Output Based Questions 7. x = 5 x += 3 print(x) a. Error b. 8 c. 5 d. 2 8 / 50 Category: Output Based Questions 8. print("Hello" + "World") a. Error b. HelloWorld c. Hello+World d. Hello World 9 / 50 Category: Output Based Questions 9. print(bool(0)) a. True b. Error c. False d. 0 10 / 50 Category: Output Based Questions 10. print(10 > 5) a. 10 b. True c. Error d. False 11 / 50 Category: Output Based Questions 11. print(len("Python")) a. 6 b. 5 c. 8 d. 7 12 / 50 Category: Output Based Questions 12. x = 10 print(x) a. x b. 0 c. Error d. 10 13 / 50 Category: Output Based Questions 13. print(2 ** 3) a. 8 b. Error c. 9 d. 6 14 / 50 Category: Output Based Questions 14. print(type(3.14)) a. int b. decimal c. float 15 / 50 Category: Output Based Questions 15. print(10 / 2) a. 2 b. Error c. 5.0 d. 5 16 / 50 Category: Syntax & Errors 1. list = 10 print(list[0]) a. TypeError b. IndexError c. 0 d. 1 17 / 50 Category: Syntax & Errors 2. int("abc") a. 0 b. abc c. ValueError d. TypeError 18 / 50 Category: Syntax & Errors 3. if 5 > 3 print("Yes") a. Logical Error b. Syntax Error c. No Error d. Indentation Error 19 / 50 Category: Syntax & Errors 4. print(x) a. NameError b. SyntaxError c. x is printed d. 0 20 / 50 Category: Syntax & Errors 5. for i in range(5) print(i) a. No Error b. Type Error c. Name Error d. Syntax Error 21 / 50 Category: Syntax & Errors 6. print("Hello) a. No Error b. Syntax Error c. Name Error d. Value Error 22 / 50 Category: Syntax & Errors 7. a = [1,2,3] print(a[5]) a. 3 b. KeyError c. None d. IndexError 23 / 50 Category: Syntax & Errors 8. def fun(): print("Hi") a. Indentation Error b. No Error c. Syntax Error d. Name Error 24 / 50 Category: Syntax & Errors 9. print(10 / 0) a. SyntaxError b. ZeroDivisionError c. infinity d. 0 25 / 50 Category: Syntax & Errors 10. print(unknown) a. 0 b. SyntaxError c. unknown d. NameError 26 / 50 Category: True / False 1. Python is case-sensitive. a. False b. True 27 / 50 Category: True / False 2. print() is used for input in Python. a. True b. False 28 / 50 Category: True / False 3. Indentation is mandatory in Python. a. False b. True 29 / 50 Category: True / False 4. Python supports multiple inheritance. a. False b. True 30 / 50 Category: True / False 5. None represents absence of a value. a. True b. False 31 / 50 Category: True / False 6. while loop executes at least once. a. True b. False 32 / 50 Category: True / False 7. Python supports object-oriented programming. a. True b. False 33 / 50 Category: True / False 8. Python code runs faster than C language. a. True b. False 34 / 50 Category: True / False 9. Tuples are mutable data types. a. False b. True 35 / 50 Category: True / False 10. = is a comparison operator in Python. a. True b. False 36 / 50 Category: Fill in the Blanks 1. The multiplication operator in Python is __________. a. X b. % c. x d. * 37 / 50 Category: Fill in the Blanks 2. The symbol used for comments in Python is __________. a. <!-- --> b. /**/ c. // d. # 38 / 50 Category: Fill in the Blanks 3. __________ function returns the length of a list. a. len() b. size() c. length() d. count() 39 / 50 Category: Fill in the Blanks 4. __________ is used to exit a loop in Python. a. end b. break c. stop d. exit 40 / 50 Category: Fill in the Blanks 5. __________ keyword is used to check a condition in Python. a. check b. if c. for d. while 41 / 50 Category: Fill in the Blanks 6. Lists in Python are enclosed within __________ brackets. a. {} b. [] c. () 42 / 50 Category: Fill in the Blanks 7. The correct file extension for Python files is __________. a. .pyt b. .pt c. .py d. .python 43 / 50 Category: Fill in the Blanks 8. Python is a __________ typed language. a. Strongly b. Dynamically c. Weakly d. Statically 44 / 50 Category: Fill in the Blanks 9. Python is an __________ language. a. Binary b. Interpreted c. Compiled d. Assembled 45 / 50 Category: Fill in the Blanks 10. The keyword used to define a function in Python is __________. a. function b. def c. fun d. define 46 / 50 Category: Fill in the Blanks 11. The value of True in Python is __________. a. 1 b. 0 c. True d. true 47 / 50 Category: Fill in the Blanks 12. Python is a __________ level programming language. a. Machine b. Assembly c. Low d. High 48 / 50 Category: Fill in the Blanks 13. __________ is used to take input from the user in Python. a. input() b. scan() c. read() d. get() 49 / 50 Category: Fill in the Blanks 14. The output of print(type(10)) is __________. a. number b. integer c. int 50 / 50 Category: Fill in the Blanks 15. Python was created by __________. a. James Gosling b. Bjarne Stroustrup c. Dennis Ritchie d. Guido van Rossum Your score isThe average score is 0% 0% Restart quiz Rate the Quiz. Thank You For Rating Us! Send feedback Like this: Table of Contents ToggleLike this: Like Loading...Share post Please Share This Share this content Opens in a new window Opens in a new window Opens in a new window Opens in a new window Read more articles Previous PostLearn Python: A Comprehensive Guide for Beginners Prajjwal Singh Tech Blogger || Web developer || Computer Networking Enthusiast || Microsoft SQL Database Management Expert || Software Debugger || Learned DOS OS Structure You Might Also Like Conditional Construct In Python October 30, 2023 MUTABLE AND IMMUTABLE TYPES IN PYTHON April 27, 2023 Learn Python: A Comprehensive Guide for Beginners May 18, 2025 Leave a ReplyCancel reply