didier/didier/utils/types/datetime.py

7 lines
289 B
Python
Raw Normal View History

2022-07-11 22:23:38 +02:00
__all__ = ["int_to_weekday"]
2022-07-01 15:46:56 +02:00
def int_to_weekday(number: int) -> str: # pragma: no cover # it's useless to write a test for this
"""Get the Dutch name of a weekday from the number"""
return ["Maandag", "Dinsdag", "Woensdag", "Donderdag", "Vrijdag", "Zaterdag", "Zondag"][number]