http://mianshi.fenzhi.com/post/1529.html

pass语句什么也不做,一般作为占位符或者创建占位程序,pass语句不会执行任何操作,比如:
while False:
pass
pass通常用来创建一个最简单的类:
class MyEmptyClass:
pass
pass在软件设计阶段也经常用来作为TODO,提醒实现相应的实现,比如:
def initlog(*args):
pass #please implement this

相关文章:

  • 2022-12-23
  • 2022-02-04
  • 2022-12-23
  • 2021-11-29
  • 2021-10-28
  • 2022-12-23
猜你喜欢
  • 2022-02-18
  • 2022-12-23
  • 2021-08-09
  • 2022-01-02
  • 2022-12-23
  • 2022-01-14
  • 2022-12-23
相关资源
相似解决方案