Reap

Reap[expr]
gives the result of evaluating expr, together with all values sown during this evaluation. Values sown with different tags are given in different lists.
Reap[exprpattern]
only yields values sown with a tag matching pattern. Reap[expr] is equivalent to Reap[expr, _].
Reap[expr, {pattern1pattern2, ...}]
uses multiple patterns.
Reap[exprpatternf]
applies f on each tag and the corresponding values sown in the form f[tag, {e1, e2, ...}].

Find the unique elements of a list, keeping their order:

Sown values are reaped by the innermost matching Reap:

When no value is sown, an empty list is returned: