結果
| 問題 | No.2460 #強調# |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-07-23 23:12:39 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.90.0) |
| 結果 |
AC
|
| 実行時間 | 1 ms / 2,000 ms |
| + 117µs | |
| コード長 | 429 bytes |
| 記録 | |
| コンパイル時間 | 332 ms |
| コンパイル使用メモリ | 80,312 KB |
| 実行使用メモリ | 9,320 KB |
| 最終ジャッジ日時 | 2026-07-13 11:18:44 |
| 合計ジャッジ時間 | 1,673 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 11 |
ソースコード
#include <iostream>
#include <string>
using namespace std;
int main() {
string S;
getline(cin, S);
int pos1 = S.find('#');
int pos2 = S.find('#', pos1 + 1);
if (pos1 != string::npos && pos2 != string::npos && pos2 > pos1 + 1) {
cout << S.substr(pos1 + 1, pos2 - pos1 - 1) << endl;
} else {
// Nếu hai dấu # liền nhau, in dòng trống
cout << endl;
}
return 0;
}