高階函數

把一個函數做爲參數傳遞給函數的函數,稱爲高階函數。函數

def func(a,b,f):    return f(a)+f(b)rest = func(3,-19,abs)print(rest)結果是22
相關文章
相關標籤/搜索