Created
June 26, 2016 15:16
-
-
Save rahulkp220/afb7d3dec788fe725f72d7324f8e4343 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def double(function): | |
def wrapper(*args,**kwargs): | |
return 2 * function(*args,**kwargs) | |
return wrapper | |
@double | |
def adder(x,y): | |
return x + y | |
print adder(1,3) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment