結果

問題 No.1692 Expectations
ユーザー neko_the_shadowneko_the_shadow
提出日時 2021-10-13 09:53:48
言語 Perl
(5.38.2)
結果
AC  
実行時間 285 ms / 2,000 ms
コード長 260 bytes
コンパイル時間 68 ms
コンパイル使用メモリ 5,860 KB
実行使用メモリ 73,280 KB
最終ジャッジ日時 2023-10-17 19:03:04
合計ジャッジ時間 2,380 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 6 ms
5,864 KB
testcase_01 AC 7 ms
5,864 KB
testcase_02 AC 6 ms
5,892 KB
testcase_03 AC 7 ms
5,996 KB
testcase_04 AC 6 ms
5,888 KB
testcase_05 AC 7 ms
6,024 KB
testcase_06 AC 7 ms
5,996 KB
testcase_07 AC 6 ms
5,864 KB
testcase_08 AC 6 ms
5,984 KB
testcase_09 AC 7 ms
5,864 KB
testcase_10 AC 104 ms
45,040 KB
testcase_11 AC 112 ms
47,268 KB
testcase_12 AC 6 ms
5,860 KB
testcase_13 AC 7 ms
5,860 KB
testcase_14 AC 20 ms
11,348 KB
testcase_15 AC 193 ms
55,360 KB
testcase_16 AC 21 ms
11,460 KB
testcase_17 AC 101 ms
31,676 KB
testcase_18 AC 39 ms
16,552 KB
testcase_19 AC 235 ms
66,044 KB
testcase_20 AC 219 ms
60,436 KB
testcase_21 AC 285 ms
73,280 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.pl syntax OK

ソースコード

diff #

use strict;
use warnings;

sub gets {
    chomp(my $line = <>);
    $line;
}

my ($n, $m) = split / /, gets;
my @a = split / /, gets;

my %h = map {$_, 1} @a;
my $max = keys(%h);
if ($max==1 && $n==$m) {
    print "$max 1\n";
} else {
    print "$max 0\n";
}

0