Answers for "how to use timedelta python 3"

1

how to construct simple timedelta in python

from datetime import timedelta
time_objects = timedelta(days = 87,hours = 14, minutes=4, seconds=90)
print(time_objects)
Posted by: Guest on October-03-2021
19

python timedelta

import datetime

today = datetime.date.today()

next_week = today + datetime.timedelta(days=7)
Posted by: Guest on October-27-2021

Python Answers by Framework

Browse Popular Code Answers by Language