結果
| 問題 | No.3420 Letter Loading |
| コンテスト | |
| ユーザー |
besukohu
|
| 提出日時 | 2026-01-11 15:27:16 |
| 言語 | C++23 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 1,072 bytes |
| 記録 | |
| コンパイル時間 | 3,279 ms |
| コンパイル使用メモリ | 339,256 KB |
| 実行使用メモリ | 7,852 KB |
| 最終ジャッジ日時 | 2026-01-11 15:27:20 |
| 合計ジャッジ時間 | 3,943 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 WA * 2 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using a2 = array<ll, 2>;
using a3 = array<ll, 3>;
bool chmin(auto& a, const auto& b) { return a > b ? a = b, 1 : 0; }
bool chmax(auto& a, const auto& b) { return a < b ? a = b, 1 : 0; }
ll mod = 998244353;
const ll INF = 1e18;
ifstream in;
ofstream out;
int main(int argc, char** argv) {
ios::sync_with_stdio(false);
cin.tie(0);
if(argc > 2) {
in.open(argv[1]);
cin.rdbuf(in.rdbuf());
out.open(argv[2]);
cout.rdbuf(out.rdbuf());
}
ll n, w, h;
cin >> n >> w >> h;
string s;
cin >> s;
vector<ll> idx(1, -1);
for(int i = 0; i < n; i++) {
if(s[i] == 'l') {
idx.push_back(i);
}
}
while(idx.size() < n + 1)
idx.push_back(n);
for(int i = 0; i < h; i++) {
for(int j = 0; j < w; j++) {
if(h - i < idx[j + 1] - idx[j]) {
cout << 'o';
} else {
cout << 'x';
}
}
cout << endl;
}
return 0;
}
besukohu