You are viewing a single comment's thread. Return to all comments →
Fun with Python :)
from collections import Counter input() socks, pairs = Counter(map(int,input().strip().split())), 0 for s in socks: pairs += socks[s]//2 print(pairs)
Seems like cookies are disabled on this browser, please enable them to open this website
Sales by Match
You are viewing a single comment's thread. Return to all comments →
Fun with Python :)