Write a program that accepts a sequence of whitespace separated words as input and prints the words after removing all duplicate words and sorting them alphanumerically.
s = raw_input()
words = [word for word in s.split(" ")]
print " ".join(sorted(list(set(words))))
The string is accepted to s and split to a list using s.split. the list is then sorted and then joined to form the output string
GLOBALSQL is the best place to learn to code the best
GLOBALSQL best code is learn place the to