- 1
Whats wrong here?? Correct it please!!
def decor(func, text): def wrap(): print("============") func() text() print("============") return wrap @decor def print_text(): print("Hello world!") @decor def my_text(): print('Im here') print_text() my_text()
3 Respostas
+ 3
Lucky Nayak there you go, see the comments inside:
https://code.sololearn.com/cbr6Ca52cx2j/?ref=app
+ 3
Remove the 'text' parameter from the decor definition and remove calling it later with text()
Should work then
0
Im not able to understand!! please provide an example!!