It's simple , First create your Python file , And then add “def Method name :” such as
print()
"""
|
v
"""
def a():
print()
If you download Python, Then you have a computer called “Lib” The file of , Open that file :
hold Python The document can be used if it is put here import Import your library
#bcd.py
def a():
print()
Try putting this in it :
import bcd
bcd.a()
Running results :
>>>
In this way, the self-made library is completed .