def generate_study_plan(start_date, end_date, study_periods, file_location=None): dates = get_partition_dates(end_date, start_date, study_periods) conferences = get_all_conferences(file_location) results = [] for segment_start, segment_end in zip(dates[:-1], dates[1:]): talks = pick_talks(segment_start, segment_end, conferences) results.append(talks) return results
def get_number_of_talks_in_most_recent_conference(): conferences = get_all_conferences() latest_conference_talk_key = sorted(conferences.keys(), reverse=True)[0] return len(conferences[latest_conference_talk_key])