9. * Hello, France
Здравейте, задачата работи на 100% с примерните инпути, но като я дам в Judge гърми всичко. Къде може да е проблемът? Условието на задачата може да се види тук - https://judge.softuni.org/Contests/Practice/Index/1725#0 Благодаря предварително!
collection_of_items = input().split("|") list_40_percent = [] budget = int(input()) ticket_price = 150 all_money_after_sell = 0 profit = 0 sum_all_new_prices = 0 for i in collection_of_items: explode = i.split("->") if budget >= float(explode[1]): if explode[0] == "Clothes": if float(explode[1]) > 50.00: continue else: article_money = float(explode[1]) budget -= article_money list_40_percent.append(round(article_money * 1.4, 2)) profit += (float(explode[1]) *1.4 - float(explode[1])) sum_all_new_prices += (float(explode[1])) * 1.4 if explode[0] == "Shoes": if float(explode[1]) > 35.00: continue else: article_money = float(explode[1]) budget -= article_money list_40_percent.append(round(article_money * 1.4, 2)) profit += (float(explode[1]) * 1.4 - float(explode[1])) sum_all_new_prices += (float(explode[1])) * 1.4 if explode[0] == "Accessories": if float(explode[1]) > 20.50: continue else: article_money = float(explode[1]) budget -= article_money list_40_percent.append(round(article_money * 1.4, 2)) profit += (float(explode[1]) * 1.4 - float(explode[1])) sum_all_new_prices += (float(explode[1])) * 1.4 else: continue print(*list_40_percent) print(f"Profit: {profit:.2f}") new_budget = budget + sum_all_new_prices if new_budget >= ticket_price: print("Hello, France!") else: print("Not enough money.")