You are viewing a single comment's thread. Return to all comments →
I try using this way
import sys linhas = sys.stdin.read().splitlines() amount = 0 X = int(linhas[0]) shoes_sizes = linhas[1].split() N = linhas[2] for linha in linhas[3:]: Customer = linha.split() shoe_size = Customer[0] price = Customer[1] if shoe_size in shoes_sizes: shoes_sizes.remove(shoe_size) amount += int(price) X -= 1 print(amount)
Seems like cookies are disabled on this browser, please enable them to open this website
collections.Counter()
You are viewing a single comment's thread. Return to all comments →
I try using this way