結果
問題 |
No.345 最小チワワ問題
|
ユーザー |
|
提出日時 | 2016-06-17 03:59:10 |
言語 | Ruby (3.4.1) |
結果 |
AC
|
実行時間 | 92 ms / 2,000 ms |
コード長 | 146 bytes |
コンパイル時間 | 62 ms |
コンパイル使用メモリ | 7,552 KB |
実行使用メモリ | 12,416 KB |
最終ジャッジ日時 | 2024-09-25 11:48:24 |
合計ジャッジ時間 | 3,965 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 29 |
コンパイルメッセージ
Syntax OK
ソースコード
str = gets.chomp p (0..str.length).to_a.map{|i|(str.slice(i..str.length).scan(/^c.*?w.*?w/).first)}.select{|s|!s.nil?}.map{|s|s.length}.min || -1