IBM interview question

Sort intervals based on end time.