Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- first_guy = input()
- second_guy = input()
- first_score = 0
- second_score = 0
- card1 = input()
- while card1 != "End of game":
- card1 = int(card1)
- card2 = int(input())
- if card1 > card2:
- first_score += card1 - card2
- elif card2 > card1:
- second_score += card2 - card1
- else:
- print("Number wars!")
- card1 = int(input())
- card2 = int(input())
- while card1 == card2:
- card1 = int(input())
- card2 = int(input())
- if card1 > card2:
- war_score = first_score
- print(f"{first_guy} is winner with {war_score} points")
- break
- else:
- war_score = second_score
- print(f"{second_guy} is winner with {war_score} points")
- break
- card1 = input()
- if card1 == "End of game":
- print(f"{first_guy} has {first_score} points")
- print(f"{second_guy} has {second_score} points")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement