Answers for "time addition in python"

0

time addition in python

from datetime import timedelta, datetime

current_date_and_time = datetime.now()
new_time = current_date_and_time + timedelta(minutes=5, hours=1)
print(new_time)
Posted by: Guest on June-23-2021

Python Answers by Framework

Browse Popular Code Answers by Language