Vidyalelo
Python · Q63

Formatting and Decorators

Programming · Python · question 63

Q63

In the following Python code, which function is the decorator? def mk(x): def mk1(): print("Decorated") x() return mk1 def mk2(): print("Ordinary") p = mk(mk2) p()

A.
p()
B.
mk()
Answer
C.
mk1()
D.
mk2()

Answer: Option B

Solution

Answer: Option B
No explanation is given for this question Let's Discuss on Board