def add(x, y): return x + y def calculate(func, x, y): return func(x, y) result = calculate(add, 4, 6) print(result) # prints 10