1.

Which of the following is false about “from-import” form of import?(a) The syntax is: from modulename import identifier(b) This form of import prevents name clash(c) The namespace of imported module becomes part of importing module(d) The identifiers in module are accessed directly as: identifierThe question was asked in semester exam.This interesting question is from Python Modules topic in section Mapping Functions and Modules of Python

Answer»

The correct answer is (B) This form of import prevents name clash

For explanation: In the “from-import” form of import, there MAY be name CLASHES because names of the imported identifiers aren’t specified ALONG with the module name.



Discussion

No Comment Found

Related InterviewSolutions