Created
February 7, 2020 06:30
-
-
Save arpitbbhayani/958bd468d1d5fe535408671d187d530d 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
@overload | |
def area(l, b): | |
return l * b | |
@overload | |
def area(r): | |
import math | |
return math.pi * r ** 2 | |
>>> area(3, 4) | |
12 | |
>>> area(7) | |
153.93804002589985 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment