Q19
How do you create a custom decorator in Python?
A.
By modifying the built-in decorators
B.
By using the @custom_decorator syntax
C.
By importing decorators from external libraries
D.
By defining a function and using the @ symbol
AnswerAnswer: Option D
Solution
Answer: Option D
Solution:
You create a custom decorator by defining a function and using the @decorator_name syntax.