Given a sorted integer array nums, remove the duplicates in-place such that each unique element appears only once. Return the new length of the array after removing duplicates. The first k elements of nums should hold the unique values.
nums = sorted array of integers
Return k where k is number of unique elements; first k elements are unique.
Example 1:
Input:
nums = [1,1,2]
Output:
2
Explanation:
After removing duplicates, the first two elements are [1,2].