結果

問題 No.179 塗り分け
ユーザー gigurururugigurururu
提出日時 2015-04-06 00:44:12
言語 Ruby
(3.3.0)
結果
WA  
実行時間 -
コード長 298 bytes
コンパイル時間 55 ms
コンパイル使用メモリ 7,552 KB
実行使用メモリ 13,056 KB
最終ジャッジ日時 2024-04-10 11:38:05
合計ジャッジ時間 59,833 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 90 ms
12,160 KB
testcase_01 AC 90 ms
12,416 KB
testcase_02 AC 91 ms
12,288 KB
testcase_03 AC 90 ms
12,288 KB
testcase_04 AC 95 ms
12,416 KB
testcase_05 AC 326 ms
13,056 KB
testcase_06 AC 206 ms
13,056 KB
testcase_07 WA -
testcase_08 AC 1,858 ms
12,416 KB
testcase_09 WA -
testcase_10 TLE -
testcase_11 AC 2,672 ms
12,288 KB
testcase_12 AC 2,668 ms
12,288 KB
testcase_13 AC 101 ms
12,544 KB
testcase_14 AC 94 ms
12,288 KB
testcase_15 AC 89 ms
12,416 KB
testcase_16 AC 88 ms
12,160 KB
testcase_17 AC 90 ms
12,288 KB
testcase_18 AC 2,469 ms
12,288 KB
testcase_19 AC 2,273 ms
12,288 KB
testcase_20 AC 2,286 ms
12,288 KB
testcase_21 AC 1,955 ms
12,416 KB
testcase_22 AC 1,958 ms
12,416 KB
testcase_23 AC 2,181 ms
12,416 KB
testcase_24 AC 1,939 ms
12,288 KB
testcase_25 AC 1,955 ms
12,416 KB
testcase_26 WA -
testcase_27 AC 2,225 ms
12,416 KB
testcase_28 WA -
testcase_29 AC 2,441 ms
12,288 KB
testcase_30 WA -
testcase_31 AC 2,546 ms
12,288 KB
testcase_32 AC 2,581 ms
12,288 KB
testcase_33 AC 2,568 ms
12,416 KB
testcase_34 WA -
testcase_35 AC 2,697 ms
12,416 KB
testcase_36 AC 91 ms
12,160 KB
testcase_37 AC 89 ms
12,160 KB
testcase_38 AC 95 ms
12,288 KB
testcase_39 AC 89 ms
12,160 KB
testcase_40 AC 90 ms
12,288 KB
testcase_41 AC 88 ms
12,160 KB
testcase_42 AC 91 ms
12,288 KB
testcase_43 AC 132 ms
13,056 KB
testcase_44 AC 356 ms
13,056 KB
testcase_45 AC 102 ms
12,928 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

H,W=gets.split.map(&:to_i)
m=(1..H).map{gets.chomp}+[""]*50

ans=false
H.times{|i|W.times{|j|
  next if i==0&&j==0

  tm=m.map{|l|l.dup}
  H.times{|h|W.times{|w|
    if tm[h][w]==?# && tm[h+i][w+j]==?#
      tm[h][w]=tm[h+i][w+j]=?.
    end
  }}

  ans = true if !(tm*"")[?#]
}}
puts ans ?:YES:"NO"
0