mirror of
https://github.com/TheAlgorithms/Python.git
synced 2025-07-05 01:09:40 +08:00
[mypy] Fix type annotations for maths (#4617)
* Fix mypy errors for armstrong_numbers.py * Fix mypy errors for harmonic_series.py * Fix mypy errors for average_median.py
This commit is contained in:
@ -33,8 +33,8 @@ def harmonic_series(n_term: str) -> list:
|
||||
['1']
|
||||
"""
|
||||
if n_term == "":
|
||||
return n_term
|
||||
series = []
|
||||
return []
|
||||
series: list = []
|
||||
for temp in range(int(n_term)):
|
||||
series.append(f"1/{temp + 1}" if series else "1")
|
||||
return series
|
||||
|
Reference in New Issue
Block a user