# Defining a Python function at runtime # importing the modulefrom types import FunctionType  # functttion during run-timef_code = compile('def gfg(): return "GEEKSFORGEEKS"', "<string>", "exec")f_func = FunctionType(f_code.co_consts[0], globals(), "gfg")  # calling the functionprint(f_func())