Created
June 13, 2018 10:35
-
-
Save martin-martin/f50aecd17a3a03d794bf2c469c2122b6 to your computer and use it in GitHub Desktop.
stayCalm created by martin_martin - https://repl.it/@martin_martin/stayCalm
This file contains 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
# a function decorator to avoid digital screaming | |
def lowercase(func): | |
def wrapper(text): | |
initial_result = func(text) | |
new_result = initial_result.lower() | |
return new_result | |
return wrapper | |
@lowercase | |
def say_something(text): | |
return text | |
print(say_something("HEI WHAT'S UP?")) | |
# hei what's up? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment