Python Learn Simpli September 6, 2019 no Comments 1. which of the following keyword(s) used along with ‘else’ clause in Python try while all of the above if None 2. What becomes the Variable used inside a function? Global variable None of these Local variable Reference variable None 3. Which is not a built-in exception in Python among following options? TypeError ImportError ValueError KeywordError None 4. Value of __name__ attribute of a module may be equal to ‘main’ when it is the first module in a package None of these it is imported by another script it is executed from interpreter None 5. What is meant by self in Python? It is a keyword. It is a built-in function in python It is a class attribute. It is reference to object which calls an instance method. None 6. For what Commit() method should be executed? Close database Finalize transactions Refresh data after execution of query Close table None 7. What kind of relationship exists between inherited class and base class? Both IS A None HAS A None 8. Which is an incorrect syntax in the following answers? import function from module from module import function import module None 9. What is a Python DB-API ? Is used to access SQLite database Python module Specification for database connectivity modules None of these None 10. What cannot be a part of Python module? Class Function Keyword none None Time's up