Back

Explore Courses Blog Tutorials Interview Questions
0 votes
1 view
in Python by (1.6k points)

What's the difference between a Python module and a Python package?

1 Answer

0 votes
by (25.1k points)

You can think of the difference between a module and a package as being almost the same as between a file and a folder respectively.

A module is a file or a collection of files that can be imported with a single import statement.

On the other hand a package is a collection of modules and packages. They are like a directory with __init__.py file.

Related questions

Welcome to Intellipaat Community. Get your technical queries answered by top developers!

28.4k questions

29.7k answers

500 comments

94.1k users

Browse Categories

...