1.    Files == Modules,  Top level module == scripts

 
2.    Module Imports and Reloads
  • Omit the .py
  • Import runs the file once per process. reload() can run mutiple times.
  • Module can contain variables, functions, etc.
  • from ... import ... :   Copy names from a module.
  • dir():   Return the attributes of a module.
  • exec(open('module.py').read()),  execfile('module.py')
3.    Advanced IDLE Tools
  • Debuger
  • object browser

相关文章:

  • 2022-12-23
  • 2021-05-21
  • 2021-06-01
  • 2022-12-23
  • 2021-11-07
  • 2022-12-23
  • 2021-12-26
  • 2022-12-23
猜你喜欢
  • 2021-09-20
  • 2021-06-04
  • 2021-06-16
  • 2021-11-06
  • 2021-09-30
  • 2021-10-27
  • 2021-11-20
相关资源
相似解决方案