3 ms·
I think py version can be shortened as: from collections import Counter stats = Counter(x.strip() for l in open(sys.argv[1]) for x in l)
by est 8mo ago
I think py version can be shortened as:
from collections import Counter
stats = Counter(x.strip() for l in open(sys.argv[1]) for x in l)
- voidUpdate 8mo agoWould that decrease memory usage though?
- est 8mo agosee https://news.ycombinator.com/item?id=47543756 https://news.ycombinator.com/item?id=47543756