Write a function named delorean that takes an integer. Return a datetime that is that many hours ahead from starter.
my output is getting this:
delorean didn't return the right datetime. Got 2015-10-21 05:29:00.
can't see where I'm getting this wrong everything is changing except the hours :(
Thanks in advanced
import datetime starter = datetime.datetime(2015, 10, 21, 16, 29) def delorean(ahead): return starter.replace(hour=ahead)
Steven Parker195,257 Points
You're close, but instead of simply replacing the hour with the argument, you need to add the argument to the current hour: