Average median type hint (#4483)

* Update average_median.py

* Wikipediad link added
This commit is contained in:
Grigoriy Hanin 2021-06-14 23:39:51 +03:00 committed by GitHub
parent 95a4957d9e
commit 0eabdb54b1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,6 +1,10 @@
def median(nums):
from typing import Union
def median(nums: Union[int, float]) -> Union[int, float]:
"""
Find median of a list of numbers.
Wiki: https://en.wikipedia.org/wiki/Median
>>> median([0])
0