.py
added.mymodule.py
` and define some variables :# mymodule.py
name = "John"
age = 35
Then, in another Python script, import the module and access the variables :
# main.py
import mymodule
print(mymodule.name)
print(mymodule.age)
main.py
` script, you should see the following output :John
35​