#!/usr/bin/env perl
use warnings;
use warnings FATAL => qw(uninitialized);
use strict;

# MAIN EXECUTION BEGINS HERE
MAIN: {
    my @output;
    my %seen;

    while (<>) {
        if (! exists($seen{$_})) {
            push @output, $_;
            $seen{$_} = 1;
        }
    }
    print join("", @output);
}
