結果

問題 No.470 Inverse S+T Problem
ユーザー tailstails
提出日時 2016-12-20 09:35:41
言語 Perl
(5.38.2)
結果
WA  
(最新)
AC  
(最初)
実行時間 -
コード長 270 bytes
コンパイル時間 173 ms
コンパイル使用メモリ 5,380 KB
実行使用メモリ 60,348 KB
最終ジャッジ日時 2023-08-24 01:14:13
合計ジャッジ時間 3,288 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 AC 445 ms
60,160 KB
testcase_07 AC 443 ms
60,152 KB
testcase_08 AC 441 ms
60,348 KB
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 AC 3 ms
4,852 KB
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 AC 3 ms
4,540 KB
testcase_20 WA -
testcase_21 WA -
testcase_22 WA -
testcase_23 WA -
testcase_24 AC 3 ms
4,660 KB
testcase_25 WA -
testcase_26 AC 3 ms
4,740 KB
testcase_27 WA -
testcase_28 AC 61 ms
13,152 KB
testcase_29 AC 11 ms
6,260 KB
testcase_30 AC 33 ms
9,552 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.pl syntax OK

ソースコード

diff #

sub e{exit!print"Impossible"}sub f{$1[$_]||=${$1[$_]="$` $'
",g($`,$')&&return 1while$@[$_]=~//g}}sub g{my($a,$b)=@_;!$v{$a}&!$v{$b}&&($v{$a}=$v{$b}=1,map{f||return$v{$a}=$v{$b}=0for@$_}$a,$b)}<>;map{chop;map{push@$_,$-}$',$`while/\B/g;++$-}@@=<>;f||e for 0..$#@;print@1
0