Question
def f(x):
def f1(*args, **kwargs):
print("*"* 5)
x(*args, **kwargs)
print("*"* 5)
return f1
def a(x):
def f1(*args, **kwargs):
print("%"* 5)
x(*args, **kwargs)
print("%"* 5)
return f1
@f
@a
def p(m):
print(m)
p("hello")
a.
*****
%%%%%
hello
%%%%%
*****
b.
Error
c.
*****%%%%%hello%%%%%*****
d.
hello
Posted under Python
%%%%%
hello
%%%%%
*****
Engage with the Community - Add Your Comment
Confused About the Answer? Ask for Details Here.
Know the Explanation? Add it Here.
Q. What are the output of the code shown below?
Similar Questions
Discover Related MCQs
Q. The ______ symbol along with the name of the decorator function can be placed above the definition of the function to be decorated works as an alternate way for decorating a function.
View solution
Q. Fill in the blanks:
The formatting method {1:<10} represents the ___________ positional argument, _________ justified in a 10 character wide field.
View solution
Q. The output of which of the codes shown below will be: “There are 4 blue birds.”?
View solution
Q. Which of the following formatting options can be used in order to add ‘n’ blank spaces after a given string ‘S’?
View solution
Suggested Topics
Are you eager to expand your knowledge beyond Python? We've curated a selection of related categories that you might find intriguing.
Click on the categories below to discover a wealth of MCQs and enrich your understanding of Computer Science. Happy exploring!