end work with others algoritms: lexicographical_compare, prev_permutation, next_permutation