Anagram

아직 제출이 없습니다시간 제한4초메모리 제한256 MB

문제

Two words are anagrams if the letters of the first word can be reordered to obtain the second one. An instance of anagrams is the pair “listen” and “silent”.

You are given a list of words, each word consisting of lowercase letters. Your goal is to filter this list by dropping any word whose anagram has already appeared earlier on the list.

입력

The first line contains nn, the length of the list. This is followed by nn lines, each containing one word.

출력

Print out the list of words without anagrams, one word per line. The words should appear in the same order as given in the input.

제한

  • 1n1051 ≤ n ≤ 10^5
  • All letters are lowercase letters of the English alphabet.
  • Length of any word will not exceed 100100.