1.导入其他模块.
import modea
from modea import test # 从 modea中导入test方法
import modea as moa #导入modea并且将命名空间变成moa
2.排除不需要执行的代码
def haha():
print("ceshi")
if __name__=="__main__":
...
3.导入不同包下的模块.
![](https://img.haomeiwen.com/i3067896/d49a53f79562c34b.png)
需要在不同的包里面加int方法
import test.mode_b
网友评论