結果
| 問題 | No.1159 Sashiming String |
| ユーザー |
|
| 提出日時 | 2020-08-12 09:08:54 |
| 言語 | Ruby (4.0.2) |
| 結果 |
AC
|
| 実行時間 | 124 ms / 2,000 ms |
| コード長 | 149 bytes |
| 記録 | |
| コンパイル時間 | 146 ms |
| コンパイル使用メモリ | 9,088 KB |
| 実行使用メモリ | 30,592 KB |
| 最終ジャッジ日時 | 2026-04-25 22:17:16 |
| 合計ジャッジ時間 | 2,478 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 12 |
コンパイルメッセージ
Syntax OK
ソースコード
cnt = 0
p gets.chomp.gsub('ing', '>').gsub('S', '<').chars.select {
'<>'.include? _1
}.sum { |c|
cnt += 1 if c == '<'
c == '>' ? cnt : 0
}