結果

問題 No.182 新規性の虜
ユーザー teio
提出日時 2020-07-26 15:22:32
言語 Perl
(5.40.0)
結果
AC  
実行時間 106 ms / 5,000 ms
コード長 287 bytes
コンパイル時間 310 ms
コンパイル使用メモリ 7,076 KB
実行使用メモリ 27,904 KB
最終ジャッジ日時 2024-06-28 16:23:25
合計ジャッジ時間 2,122 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 27
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.pl syntax OK

ソースコード

diff #

# use strict;
# use warnings;

<>;
chomp(my $s = <>);
my @As = split(/\s/, $s);
my %d;
my %c;
foreach (@As) {
    next if exists($c{$_});
    if (exists($d{$_})) {
        delete $d{$_};
        $c{$_} = undef;
    } else {
        $d{$_} = undef;
    }
}
print(scalar(keys(%d)), "\n");
0