I would recommend using $seen{$_}++ over
$seen{$_}=1 because with the former you have
additional information, such as how many times you have
seen that particular item. This can be useful for
detecting duplicate keys, for example.
As such, these two are perhaps functionally the same in a
narrow set of circumstances. Using the ++ approach is
much more adaptable, so it should be used in preferance to
simple assignment.