Python 函数两括号()() ()(X)的语法含义

看下面一个例子就知道了

def func(d):
    print("this is func");
    print(d);
    def func8(x):
        print(x);
    return func8;
 
func(20)(9)

输出是:

this is func
20
9

简单明了

posted on 2018-10-06 06:44  哈希茶馆  阅读(1441)  评论(0)    收藏  举报

导航