def get_availabilities_for_duration(duration, availabilities):
duration_availabilities = []<EOL>start_time = '<STR_LIT>'<EOL>while start_time != '<STR_LIT>':<EOL><INDENT>if start_time in availabilities:<EOL><INDENT>if duration == <NUM_LIT:30>:<EOL><INDENT>duration_availabilities.append(start_time)<EOL><DEDENT>elif increment_time_by_thirty_mins(start_time) in availabilities:<EOL><INDENT>duration_availabilities.append(start_time)<EOL><DEDENT><DEDENT>start_time = increment_time_by_thirty_mins(start_time)<EOL><DEDENT>return duration_availabilities<EOL>
Helper function to return the windows of availability of the given duration, when provided a set of 30 minute windows.