How to Create a Python Package
We'll cover the following...
The main difference between a module and a package is that a package is a collection of modules AND it has an __init__.py file. Depending on the complexity of the package, it may have more than one __init__.py. Let’s take a look at a simple folder structure to make this more obvious, then we’ll create some simple code to follow the structure we define.
Press + to interact
mymath/__init__.pyadv/__init__.pysqrt.pyadd.pysubtract.pymultiply.pydivide.py
Now we just need to replicate this structure in our own package. Let’s give that a whirl! Create ...
Access this course and 1400+ top-rated courses and projects.