ChatDev/WareHouse/WaterBreakv2_ModelBest1024_20231026175200/schedule.py
2023-10-26 19:16:07 +08:00

11 lines
360 B
Python

'''
This file contains the logic for generating the schedule of water breaks.
'''
from datetime import timedelta
def generate_schedule(start_time, end_time, interval):
schedule = []
current_time = start_time
while current_time < end_time:
schedule.append(current_time)
current_time += timedelta(minutes=interval)
return schedule