結果
| 問題 | No.342 一番ワロタww |
| コンテスト | |
| ユーザー |
femto
|
| 提出日時 | 2016-08-20 16:02:54 |
| 言語 | C++11(廃止可能性あり) (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 791 bytes |
| 記録 | |
| コンパイル時間 | 1,529 ms |
| コンパイル使用メモリ | 75,700 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-11-07 21:34:52 |
| 合計ジャッジ時間 | 2,249 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 3 |
| other | AC * 3 WA * 11 |
ソースコード
#include <iostream>
#include <fstream>
#include <vector>
#include <cstring>
#include <string>
#include <algorithm>
#include <iomanip>
using namespace std;
typedef pair<int, string> P;
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
vector<P> v;
string s;
cin >> s;
int n = s.size(), p = 0;
while(p < n && s[p] == -126 && s[p + 1] == -105) p += 2;
int m = 0;
while(p < n) {
string t;
while(p < n && !(s[p] == -126 && s[p + 1] == -105)) {
t += s[p];
t += s[p + 1];
p += 2;
}
int wc = 0;
while(p < n && s[p] == -126 && s[p + 1] == -105) {
wc++;
p += 2;
}
m = max(m, wc);
v.emplace_back(wc, t);
}
if(v.size() == 0 || m == 0) {
cout << endl;
}
else {
for(P val : v) {
if(m == val.first) {
cout << val.second << endl;
}
}
}
}
femto