Computer Science

Why is from import* statement not recommended for importing Python modules in an external program?

Python Modules

4 Likes

Answer

Using from module_name import * is not recommended because it can lead to namespace pollution, reduce code readability, introduce unnecessary imports, and increase the risk of errors due to unintended or conflicting names.

Answered By

2 Likes


Related Questions