Created
September 5, 2018 17:51
-
-
Save DamnedFacts/e8f696fdb90bb25604431617e2e8fa42 to your computer and use it in GitHub Desktop.
Create a schedule of dates from a start date, through a total number of weeks, with optional weekly skipping
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from datetime import date, timedelta | |
| def ta_meetings(year, month, day, skip_weeks=2, total_weeks=15): | |
| for dd in range(0, total_weeks, skip_weeks): | |
| d = date(year, month, day) + timedelta(days=dd*7) | |
| print(d.strftime("%a, %d %b %Y, B&L 470, 3:00-3:30pm")) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment