代码
#!/usr/bin/env python # encoding: utf-8 import sys import platform def a(vale1): def b(valeb): if valeb > vale1: print("%d is pass"%valeb) else: print("%d is fales"%valeb) return b c = a(60) d = a(90) c(59) c(89) d(89)#闭包函数 print (platform.python_version()) #显示python版本 3.5.1 print (sys.version) #显示python版本 3.5.1 (v3.5.1:37a07cee5969, Dec 6 2015, 01:54:25) [MSC v.1900 64 bit (AMD64)]