Advertisement
dsavov_02

subtitute

Dec 11th, 2021
940
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.58 KB | None | 0 0
  1. first = int(input())
  2. second = int(input())
  3. third = int(input())
  4. forth = int(input())
  5. combinations = 0
  6. for k in range(first, 8):
  7.     for p in range(9, second):
  8.         for m in range(third, 8):
  9.             for n in range(9, forth):
  10.                 if k == m & p == n & k % 2 == 0 & p % 2 != 0:
  11.                     print("Cannot change the same player.")
  12.                 elif k % 2 == 0 & p % 2 != 0 & m % 2 == 0 & n % 2 != 0:
  13.                     print(f"{k}{p} - {m}{n}")
  14.                     combinations += 1
  15.                 if combinations == 6:
  16.                     exit()
  17.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement