mirror of https://github.com/01-edu/public.git
eslopfer
2 years ago
1 changed files with 0 additions and 9 deletions
@ -1,9 +0,0 @@
|
||||
def clean_list(shopping_list): |
||||
if shopping_list: |
||||
cleaned_list = ([f"{index + 1}/ {item.strip().capitalize()}" |
||||
for index, item in enumerate(shopping_list)]) |
||||
if "Milk" not in shopping_list: |
||||
cleaned_list.append(f"{len(cleaned_list)}/ Milk") |
||||
return cleaned_list |
||||
else: |
||||
return [] |
Loading…
Reference in new issue