add longest consecutive sequence of an unsorted array