Skip to content

Commit

Permalink
Update remove_the_minimum.py
Browse files Browse the repository at this point in the history
  • Loading branch information
ikostan committed Dec 20, 2024
1 parent c152e44 commit 9e49c0b
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions kyu_7/remove_the_minimum/remove_the_minimum.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,5 @@ def remove_smallest(numbers: list) -> list:

min_num: int = min(numbers)
min_i: int = numbers.index(min_num)
for i, el in enumerate(numbers):
if i != min_i:
new_array.append(el)

new_array = [el for i, el in enumerate(numbers) if i != min_i]
return new_array

0 comments on commit 9e49c0b

Please sign in to comment.