[ create a new paste ] login | about

Link: http://codepad.org/jCVy3B1Q    [ raw code | output | fork ]

Python, pasted on Feb 9:
1
2
3
4
5
from datetime import datetime, timedelta
a = datetime(2018,10,2,10) 
d = 30
e = a + timedelta(hours=d)
print a, e


Output:
1
2018-10-02 10:00:00 2018-10-03 16:00:00


Create a new paste based on this one


Comments: