結果
| 問題 |
No.273 回文分解
|
| コンテスト | |
| ユーザー |
horiesiniti
|
| 提出日時 | 2017-09-15 13:29:06 |
| 言語 | Ruby (3.4.1) |
| 結果 |
AC
|
| 実行時間 | 90 ms / 2,000 ms |
| コード長 | 152 bytes |
| コンパイル時間 | 81 ms |
| コンパイル使用メモリ | 7,552 KB |
| 実行使用メモリ | 12,416 KB |
| 最終ジャッジ日時 | 2024-06-25 13:53:19 |
| 合計ジャッジ時間 | 4,153 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 32 |
コンパイルメッセージ
Syntax OK
ソースコード
s=gets.chomp
ans=0
s.size.times{|i|
(s.size-i).times{|j|
t=s[i,j+1]
if s!=t && t==t.reverse && ans<t.size then
ans=t.size
end
}
}
puts ans
horiesiniti