Дан код. Как называется данный прием?

def f(n):

def g(x):

return x ** n

return g



g = f(3)

print(g(2), g(3))