def action(): print 'in the action' logger()action()报错NameError: global name 'logger' is not defineddef logger(): print 'in the logger'def action(): print 'in the action' logger() action() def action(): print 'in the action' logger()def logger(): print 'in the logger' action()