Advertisement
pacho_the_python

Untitled

Mar 3rd, 2022
114
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.31 KB | None | 0 0
  1. number_list = list(map(int, input().split(", ")))
  2.  
  3. group = 10
  4.  
  5. while True:
  6.     if len(number_list) == 0:
  7.         break
  8.  
  9.     current_list = [x for x in number_list if x <= group]
  10.  
  11.     for y in current_list:
  12.         number_list.remove(y)
  13.  
  14.     print(f"Group of {group}'s: {current_list}")
  15.     group += 10
  16.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement