Next Permutation Leetcode Solution 330