Refactored findFreeTimeSlots