how to subtract 48 hours from datetime filed in python without using pandas

Solutions on MaxInterview for how to subtract 48 hours from datetime filed in python without using pandas by the best coders in the world

showing results for - "how to subtract 48 hours from datetime filed in python without using pandas"
Alessandra
10 Sep 2018
1from datetime import datetime, timedelta
2
3d = datetime.today() - timedelta(hours=0, minutes=50)
4
5d.strftime('%H:%M %p')
6