0% found this document useful (0 votes)
24 views1 page

Simple Questions

Uploaded by

kefep22283
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views1 page

Simple Questions

Uploaded by

kefep22283
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

1. Explain the difference between mutable and immutable data types with examples.

2. How are sets different from lists and dictionaries in Python?


3. How do you create a multi-dimensional list in Python?
4. Can you describe how to iterate over a dictionary in Python?
5. Can you provide an example of a scenario where a nested dictionary would be
useful?
6. Discuss the concept of slices in Python and how they apply to sequences.
7. What are the key differences between list and set data types?
8. What is the difference between lists and tuples in Python?
9. How are sets different from lists and dictionaries in Python?
10. How do you write an if statement with multiple conditions in Python?
11. Describe Python’s if-elif-else statement.
12. What is a for loop, and how does it work in Python?
13. Explain the while loop and give an example of its usage
14. Explain the difference between the if, elif, and else statements.
15. What is the purpose of the if __name__ == "__main__": block in Python scripts?
16. Explain the use of the in and not in operators in Python conditional statements.
17. Describe the range() function in Python and its usage in for loops.
18. What is a decorator in Python? How is it related to OOP?
19. What is the purpose of the self keyword in methods?
20. Are there any limitations of Inheritance?
21. What is an interface?
22. What is an abstract class?
23. How is an abstract class different from an interface?
24. What is the difference between a parameterized constructor and a non-
parameterized constructor?

You might also like