結果
| 問題 |
No.392 2分木をたどれ
|
| コンテスト | |
| ユーザー |
not_522
|
| 提出日時 | 2016-12-17 00:44:47 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 7 ms / 2,000 ms |
| コード長 | 436 bytes |
| コンパイル時間 | 1,616 ms |
| コンパイル使用メモリ | 168,236 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-11-30 22:10:50 |
| 合計ジャッジ時間 | 1,840 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 3 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
struct Initializer {
Initializer() {
cin.tie(0);
ios::sync_with_stdio(0);
cout << fixed << setprecision(15);
}
} initializer;
int main() {
int m;
cin >> m;
for (int i = 0; i < m; ++i) {
int a;
cin >> a;
string res;
for (++a; a != 1; a /= 2) {
res += a % 2 ? "R" : "L";
}
reverse(res.begin(), res.end());
cout << res << endl;
}
}
not_522