Question 1: Python Complex Numbers
Which is the correct way to declare a complex number in Python?
Question 2: Python Membership Operators
What will be the output?
Question 3: Python List to String
What will be the output of this code?
Question 4: Python Infinite While Loop
Which of the following will create an infinite loop?
Question 5: Python Match Default Case
What symbol is used for the default case in Python match statements?
Question 6: Python Functions - Anonymous Functions
Which of the following correctly defines a lambda function to double a number?
Question 7: Python Lists - Slicing
What will this code output?
Question 8: Python Dictionaries - Updating Values
What will be the output?
Question 9: Python Strings - len() Function
What does the following return?
Question 10: Python OOPs - Method Overriding
What is method overriding?
Question 11: Python Type Checking
Which function is used to check the type of a variable in Python?
Question 12: Python Bitwise Operator
What is the result of 6 & 3?
Question 13: Python Float String Conversion
What is the output of this code?
Question 14: Python Nested Loop
What will be the output?
Question 15: Python Match Multiple Patterns
What will this code print?
Question 16: Python Functions - Built-in map()
What will be the output?
Question 17: Python Lists - Nested Lists
What is the output?
Question 18: Python Sets - Union Operation
What is the output?
Question 19: Python Strings - String Methods
What will this output?
Question 20: Python OOPs - self Keyword
What is the purpose of self in a class method?