結果
| 問題 | No.455 冬の大三角 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2016-12-06 00:06:51 |
| 言語 | Ruby (3.4.1) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 247 bytes |
| 記録 | |
| コンパイル時間 | 308 ms |
| コンパイル使用メモリ | 7,552 KB |
| 実行使用メモリ | 12,288 KB |
| 最終ジャッジ日時 | 2024-11-27 21:56:58 |
| 合計ジャッジ時間 | 7,662 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 3 |
| other | WA * 46 RE * 8 |
コンパイルメッセージ
Main.rb:1: warning: assigned but unused variable - h Syntax OK
ソースコード
h,w = gets.split.map(&:to_i)
y = 0
star = []
while cin=gets
if cin=~/(-*)\*/
x = $1.size
star << [x,y]
end
y+=1
end
if star[0][0] == star[1][0] && star[0][0]==0
puts "-*"+"-"*(w-2)
else
puts "*"+"-"*(w-1)
end