Created
May 21, 2021 13:03
-
-
Save modos/b1231acb39a1501f882046230eac1694 to your computer and use it in GitHub Desktop.
استارتاپ با کلاس
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
target = [int(i) for i in input().split(" ")] | |
persons = [0 for i in range(4)] | |
counter = 0 | |
while True: | |
if 0 in target: | |
break | |
else: | |
target[0] -= 1 | |
target.insert(0, target[-1]) | |
target.pop() | |
target.insert(0, target[-1]) | |
target.pop() | |
if counter == 4: | |
counter = 0 | |
persons[counter] += 1 | |
counter += 1 | |
persons = [str(i) for i in persons] | |
print(" ".join(persons)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment