Python no extra memory used

  • 0
    class Solution(object):
        def removeDuplicates(self, nums):
            :type nums: List[int]
            :rtype: int
            if nums==[]:
                return nums
            for i in uniq:
                if nums.count(i)>2:
                    while nums.count(i)!=2:
            return nums        

    Please provide your reviews and suggest in improvising code. Thanks in advance

Log in to reply

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.