1
2
>>> [ xs[i] for i in xrange(0, len(xs)) if xs[i] not in xs[:i] ]
[3, 1, 4, 5, 9, 2, 6, 8, 7]