Skip to content

Instantly share code, notes, and snippets.

@rrguntaka
Created November 1, 2018 02:59
Show Gist options
  • Save rrguntaka/faf0c4fe876d8383fa3da36ec7e819eb to your computer and use it in GitHub Desktop.
Save rrguntaka/faf0c4fe876d8383fa3da36ec7e819eb to your computer and use it in GitHub Desktop.
import datetime
dt = datetime.datetime(2018, 1, 22)
end = datetime.datetime(2018, 12, 31)
step = datetime.timedelta(days=14)
result = []
while dt < end:
result.append(dt.strftime('%d-%b-%Y'))
dt += step
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment