結果

問題 No.189 SUPER HAPPY DAY
ユーザー tailstails
提出日時 2015-04-22 00:56:09
言語 Perl
(5.38.2)
結果
WA  
実行時間 -
コード長 496 bytes
コンパイル時間 234 ms
コンパイル使用メモリ 5,216 KB
実行使用メモリ 11,396 KB
最終ジャッジ日時 2023-09-18 07:09:44
合計ジャッジ時間 19,981 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 689 ms
10,992 KB
testcase_01 AC 685 ms
11,040 KB
testcase_02 AC 689 ms
11,252 KB
testcase_03 AC 686 ms
11,060 KB
testcase_04 AC 692 ms
10,988 KB
testcase_05 AC 689 ms
11,228 KB
testcase_06 AC 687 ms
11,232 KB
testcase_07 AC 695 ms
11,208 KB
testcase_08 AC 693 ms
11,232 KB
testcase_09 AC 695 ms
11,072 KB
testcase_10 AC 688 ms
11,248 KB
testcase_11 AC 690 ms
11,068 KB
testcase_12 AC 687 ms
11,056 KB
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 WA -
testcase_23 WA -
testcase_24 WA -
testcase_25 WA -
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.pl syntax OK

ソースコード

diff #

$mod=1000000009;

@0=(1);
for$n(1..200){
    for$i(0..$n*9){
	for$d(0..9){
	    ($$n[$i+$d]+=${$n-1}[$i])%=$mod;
	}
    }
}

<>=~$";$M=$`+1;$D=$'+1;

$o=0;
$_=$M;
while($_){
  s/.//;
  $l=length;
  for$i(0..@$l){
    for$d(0..$&-1){
      ($M[$o+$i+$d]+=$$l[$i])%=$mod;
    }
  }
  $o+=$&;
}

$o=0;
$_=$D;
while($_){
  s/.//;
  $l=length;
  for$i(0..@$l){
    for$d(0..$&-1){
      ($D[$o+$i+$d]+=$$l[$i])%=$mod;
    }
  }
  $o+=$&;
}

for(1..2010){
  $r=($r+$D[$_]*$M[$_]%$mod)%$mod;
}
print$r;
0