Skip to content

Commit 598f444

Browse files
add python solution for removeElement
1 parent a805069 commit 598f444

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
2+
def removeElement(nums, val):
3+
while val in nums:
4+
nums.remove(val)
5+
return len(nums)

0 commit comments

Comments
 (0)