This quiz works best with JavaScript enabled. Home > Class 11 > Class 11 Computer Science Chapter 2 Introduction To Python – Quiz 59 🏠 Homepage 📘 Download PDF Books 📕 Premium PDF Books Class 11 Computer Science Chapter 2 Introduction To Python Quiz 59 (25 MCQs) Quiz Instructions Select an option to see the correct answer instantly. 1. What is the difference between a string and an integer in Python? A) A string is a numeric value; an integer is a sequence of characters. B) A string is always longer than an integer; an integer is always shorter than a string. C) A string is a sequence of characters; an integer is a whole number. D) A string can only contain letters; an integer can contain letters and numbers. Show Answer Correct Answer: C) A string is a sequence of characters; an integer is a whole number. 2. Which of the following has only unique values? A) List. B) Dictionary. C) Set. D) Tuple. Show Answer Correct Answer: C) Set. 3. What will happen if indentation is not used properly in Python? A) The code will still execute but give incorrect results. B) Python will raise an IndentationError. C) Python ignores indentation. D) The program will execute partially. Show Answer Correct Answer: B) Python will raise an IndentationError. 4. What is the output of the expression 3 * 4 + 5? A) 17. B) 15. C) 20. D) 12. Show Answer Correct Answer: A) 17. 5. You use ..... blocks to program Scratch A) Code. B) Algorithm. C) Sequence. D) Memory. Show Answer Correct Answer: A) Code. 6. Which of the following is true about the subprograms in the turtle graphics library module? A) They require the name of the turtle you create to the left of the dot. B) They use the library name "turtle" or a variable. C) They can only be used after the turtle window is closed. D) They are not compatible with the PLS. Show Answer Correct Answer: B) They use the library name "turtle" or a variable. 7. What does input() do in Python? A) Prints text. B) Asks the user to type something. C) Runs a game. D) Opens the browser. Show Answer Correct Answer: B) Asks the user to type something. 8. What should you do to repeat the drawing of the Slinky circles? A) Delete the old code. B) Ignore the code. C) Write new code. D) Copy and paste the code. Show Answer Correct Answer: D) Copy and paste the code. 9. Which of these is a number in Python? A) "cat". B) 42. C) 'name'. D) "5". Show Answer Correct Answer: B) 42. 10. Which of the following types of computer languages that can be human readable and writable to communicate the computer? A) Assembly languages. B) Machine languages. C) Low-level languages. D) High-level languages. Show Answer Correct Answer: D) High-level languages. 11. Which of these is a list in Python? A) \{1, 2, 3\}. B) [1, 2, 3]. C) (1, 2, 3). D) <1, 2, 3>. Show Answer Correct Answer: B) [1, 2, 3]. 12. What does the term 'machine code' refer to? A) Code that is written in a high-level programming language. B) Code that can be understood and executed by a computer. C) Code that is only readable by programmers. D) Code that is used for graphic design. Show Answer Correct Answer: B) Code that can be understood and executed by a computer. 13. Age=14print(Age)What is the output? A) 14. B) =14. C) Age. D) None of the above. Show Answer Correct Answer: A) 14. 14. Library NumPy fokus pada ..... A) Grafik visual. B) Komputasi saintifik dengan array. C) Pemrosesan teks yang sangat cepat dan efektif serta direkomendasi. D) Analisis regresi. Show Answer Correct Answer: B) Komputasi saintifik dengan array. 15. What is the effect of using 'del []' in PLS? A) It adds an item to the end of the list. B) It removes the item at from the list. C) It inserts an item just before an existing one at. D) It creates a new empty list. Show Answer Correct Answer: B) It removes the item at from the list. 16. What type of value does input() return in Python? A) Int. B) Str. C) Float. D) Bool. Show Answer Correct Answer: B) Str. 17. Read the Python program below:a = 13 a = a + 1 print(a)When this program is executed, what will be displayed on the screen? A) 13. B) 14. C) 13 14. D) There is an error in the program because there are no values for variable a that could be used in the equation in line 3. Show Answer Correct Answer: B) 14. 18. Which of the following is a Python data type? A) Int. B) Float. C) Str. D) All of the above. Show Answer Correct Answer: D) All of the above. 19. What is a function? A) A chunk of code that performs an action. B) A type of variable. C) An error in the program. D) None of the above. Show Answer Correct Answer: A) A chunk of code that performs an action. 20. What does the if statement do? A) Prints text. B) Repeats code. C) Makes choices. D) Stores data. Show Answer Correct Answer: C) Makes choices. 21. What is data output? A) Data that put in to the computer. B) Data that is sent out to the user after processing. C) Data processing. D) None of the above. Show Answer Correct Answer: B) Data that is sent out to the user after processing. 22. You have t1 = (1, 2, 3) and t2 = ('a', 'b'). What is tuple(zip(t1, t2))? A) ((1, 'a'), (2, 'b')). B) ((1, 'a'), (2, 'b'), (3, 'c')). C) ((1, 'a'), (2, 'b'), (3, None)). D) ((1, 'a'), (2, 'b'), ('c', 3)). Show Answer Correct Answer: A) ((1, 'a'), (2, 'b')). 23. Which of the following is a Tkinter widget? A) Label. B) Button. C) Entry. D) All of the above. Show Answer Correct Answer: D) All of the above. 24. What, if anything, is wrong with the following?input=x("Type your password: ")print(x) A) The variable should be switched with the input command. B) Input commands don't need ( ). C) You can't print x. D) Nothing is wrong. Show Answer Correct Answer: A) The variable should be switched with the input command. 25. Which of the following is a valid variable assignment in Python? A) User name = 'Daisy'. B) Name-123 = 'Bob'. C) 1name = 'Alice'. D) Name = 'Charlie'. Show Answer Correct Answer: D) Name = 'Charlie'. ← PreviousNext →Related QuizzesClass 11 Computer Science Chapter 2 Introduction To Python Quiz 1Class 11 Computer Science Chapter 2 Introduction To Python Quiz 2Class 11 Computer Science Chapter 2 Introduction To Python Quiz 3Class 11 Computer Science Chapter 2 Introduction To Python Quiz 4Class 11 Computer Science Chapter 2 Introduction To Python Quiz 5Class 11 Computer Science Chapter 2 Introduction To Python Quiz 6Class 11 Computer Science Chapter 2 Introduction To Python Quiz 7Class 11 Computer Science Chapter 2 Introduction To Python Quiz 8Class 11 Computer Science Chapter 2 Introduction To Python Quiz 9Class 11 Computer Science Chapter 2 Introduction To Python Quiz 10 🏠 Back to Homepage 📘 Download PDF Books 📕 Premium PDF Books