結果

問題 No.274 The Wall
ユーザー tails
提出日時 2015-08-28 23:30:25
言語 Perl
(5.40.0)
結果
AC  
実行時間 7 ms / 2,000 ms
コード長 120 bytes
コンパイル時間 377 ms
コンパイル使用メモリ 7,580 KB
実行使用メモリ 7,324 KB
最終ジャッジ日時 2025-03-17 18:46:38
合計ジャッジ時間 1,065 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 23
権限があれば一括ダウンロードができます
コンパイルメッセージ
Name "main::n" used only once: possible typo at Main.pl line 1.
Name "main::a" used only once: possible typo at Main.pl line 5.
Main.pl syntax OK

ソースコード

diff #

($n,$m)=<>=~/\d+/g;
for(<>){
	($l,$r)=//g;
	for($l..$r,$m-1-$r..$m-1-$l){
		exit!print"NO"if++$a[$_]>2;
	}
}
print"YES";
0