Created
December 8, 2017 03:31
-
-
Save tera3939/629615d22a549c11335b50384b04b1c8 to your computer and use it in GitHub Desktop.
https://paiza.jp/learning/word-count を一行でウェイってする奴
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[print(*t) for terms, used in zip([input().split()], [set()]) for t in map(lambda x: (x, terms.count(x)), terms) if t not in used and (used.add(t) or True)] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment