''' 两句口诀理解闭包与装饰器 1.闭包:至少两层楼,楼下变量管上楼,return上楼不动手 2.装饰器:客人空手来,还得请上楼,干啥都同意,有参给上楼 ''' def secondFloor(func): def thirdFloor(): print('源函数开始执行了') func() pr Read More
posted @ 2021-02-01 08:57 LDM_datos Views(84) Comments(0) Diggs(0) Edit