Home 20 Most Important Question of Python Language || Python Programming || Computer Technology || Edu Verse BY Pratik || Code With Pratik Pratik Patel -August 10, 2024 0 Solve This Quiz and See Your Answer Python Quiz 1 Python Quiz1 Question 1: Who developed the Python language? A)Zim Den B)Guido van Roosum C)Niene Stom D)Wick van Rossum Question 2: In which year was the Python language developed A)1995 B)1972 C)1981 D)1989 Question 3: Which one of the following is the correct extension of the Python file? A) .py B) .python B) .p B) None of these Question 4: What do we use to define a block of code in Python language? A)Key B)Brackets C)Identation D)None of these Question 5: Which character is used in Python to make a single line comment? A)/ B)// C)! D)# Question 6: Which of the following statements is correct regarding the object-oriented programming concept in Python? A)Classes are real-world entities while objects are not real B)Objects are real-world entities while classes are not real C)Both object and classes are real-world entities D)All of these Question 7: Which of the following declaratons is correct? A)1num = 5 B)num1= 4 C)num 1 = 4 D)None of these Question 8: Which of the following is not a keyword in Python language? A)Val B)With C)Try D)Raise Question 9: Which of the following operators is the correct option for power(ab)? A)a ^ b B)a ** b C)a ^^ b D)a ^ * b Question 10: Which of the following declalaration is incorrect in python language? A)xyzp = 5,000,000 B)x y z p = 5000 6000 7000 8000 C)x,y,z,p = 5000, 6000, 7000, 8000 D)x_y_z_p = 5,000,000 Question 11: What is the correct syntax to output "Hello World" in Python? A)p("Hello World") B)echo("Hello World") C)print("Hello World") D)echo "Hello World" Question 12: Which one is not a legal variable name? A)Myvar B)_myvar C)my-var D)my_var Question 13:How do you create a variable with the numeric value 5? A) x = 5 B)_ x = 5 C)x = int(5) D) A and C Both Question 14: How do you create a variable with the floating number 2.8? A)x = float(2.8) B)x _ = 2.8 C)x = 2.8 D)A and C both Question 15: What is the correct syntax to output the type of a variable or object in Python? A) print(typeof(x)) B) print(typeof x) C)print(typeOf(x)) D)print(type(x)) Question 16:What is the correct syntax to return the first character in a string? A)x = "Hello".sub(0,1) B)x = sub("Hello", 0,1) C)x = "Hello"[0] D)None of these Question 17:Which method can be used to replace parts of a string? A) repl() B) switch() C) replaceString D)replace() Question 18:Which operator is used to multiply numbers? A)# B)* C)% D)X Question 19:Which operator can be used to compare two values? A)== B)= C) >< D)<> Question 20:How do you start writing an if statement in Python? A)if x > y: B)if x > y then: C)if (x > y) D)None of these Submit Facebook Twitter