Class 11 Computer Science Chapter 9 Practical Work Python Exercises Quiz 15 (30 MCQs)

Quiz Instructions

Select an option to see the correct answer instantly.

1. What is the name of the method that is always called when a new object is created from a class?
2. Which of these is correct Python conditional statement?
3. What will be printed to the screen?x = 5y = "John"print (x + y)
4. Makes it easy to repeat steps over and over
5. The order of the commands in a program.
6. Which symbol is used to make a comment line in Python?
7. Numbers = [1, 2, 3, 4, 5]Which of the following code removes all the elements from the list but retains the list
8. Select the correct operator for subtraction:
9. What is the index of "grape" in the list[ "apple" , "grape" , "orange" , "watermelon" ]?
10. What will be the value of variable y after execution of following Python code?x="55"y=x + str(9)
11. The rules for how programming languages statements can be assembled is known as
12. What is the Python Software Foundation?
13. How many parameters are there in the sum() function call below?sum(1, 3, 5)
14. If I want to store multiple names in variables, which of the following would be good variable names in best practice?
15. A while loop is used when
16. What is the output of the following list function?sampleList = [10, 20, 30, 40, 50]sampleList.append(60)print(sampleList)sampleList.append(60)print(sampleList)
17. Which of these definitions correctly describes a module?
18. Which two statements are used to implement iteration?
19. Which function allows us to add one element to a list at a desired location?
20. Which function can be used to convert list to a tuple
21. What is the output of program below?mariana ..... islands = ['Saipan', 'Tinian', 'Rota']del mariana ..... islands[0]print(mariana ..... islands)
22. Look at the following code:name = "John"age = 23What type of data is stored in the variable name?
23. ..... statement are used to assign a value to a variable.
24. Name the keyword used to define a function.
25. In the following code, what type of variable is being created?foo = "3"
26. Which of these in not a core data type?
27. A file or set of files with related variables, functions, and classes that can be reused in other programs defines
28. Look at the following code:name = input ("What is your name? ")name = input ("What is your age? ")If the user answered "John" to the first question and "23" to the second, what type of data is in name?
29. Mathematical operations can be performed on a string
30. In which year Python was developed