Aug-27-2018, 11:36 AM
politics_dict = {'Ляшко': '1', 'Порошенко': '2', 'Яценюк': '3', 'Тимошенко': '4'} pol1 = (str(input('Хто буде бити ? (Виберіть цифру)\n'))) pol2 = (str(input('Кого будуть бити ? (Виберіть цифру\n'))) if pol1 == '2' and pol2 == '1': print(poroh.attack(lyashko)) elif pol1 == '2' and pol2 == '3': poroh.attack(yacenyuk) elif pol1 == '2' and pol2 == '4': poroh.attack(tymoshenko)Im making a game and I don`t know how to avoid theese if, elif statments, is there a way to not write a huge code ?