class Solution:
    def removeDuplicates(self, nums):
        x = 1
        for i in range(len(nums)-1):
            if(nums[i]!=nums[i+1]):
                nums[x] = nums[i+1]
                x+=1
        return(nums[:x])
    

x = Solution()
print(x.removeDuplicates([1,1,1,2,2,3,4,5,5,5,6,6,7,9]))
c33107d9ed4ddfa25582b0e74d0e1b6d03dd1973
class Solution:
    <mask token>


<mask token>

class Solution:

    def removeDuplicates(self, nums):
        x = 1
        for i in range(len(nums) - 1):
            if nums[i] != nums[i + 1]:
                nums[x] = nums[i + 1]
                x += 1
        return nums[:x]


<mask token>

class Solution:

    def removeDuplicates(self, nums):
        x = 1
        for i in range(len(nums) - 1):
            if nums[i] != nums[i + 1]:
                nums[x] = nums[i + 1]
                x += 1
        return nums[:x]


<mask token>
print(x.removeDuplicates([1, 1, 1, 2, 2, 3, 4, 5, 5, 5, 6, 6, 7, 9]))

class Solution:

    def removeDuplicates(self, nums):
        x = 1
        for i in range(len(nums) - 1):
            if nums[i] != nums[i + 1]:
                nums[x] = nums[i + 1]
                x += 1
        return nums[:x]


x = Solution()
print(x.removeDuplicates([1, 1, 1, 2, 2, 3, 4, 5, 5, 5, 6, 6, 7, 9]))

class Solution:
    def removeDuplicates(self, nums):
        x = 1
        for i in range(len(nums)-1):
            if(nums[i]!=nums[i+1]):
                nums[x] = nums[i+1]
                x+=1
        return(nums[:x])
    

x = Solution()
print(x.removeDuplicates([1,1,1,2,2,3,4,5,5,5,6,6,7,9]))