結果
問題 | No.392 2分木をたどれ |
ユーザー |
|
提出日時 | 2021-07-04 00:58:28 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 4 ms / 2,000 ms |
コード長 | 358 bytes |
コンパイル時間 | 2,216 ms |
コンパイル使用メモリ | 195,324 KB |
最終ジャッジ日時 | 2025-01-22 17:22:47 |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 3 |
ソースコード
#include <bits/stdc++.h> using namespace std; int main(void) { cin.tie(0); ios::sync_with_stdio(false); int m, t; cin >> m; for (int i = 0; i < m; i++) { cin >> t; string res; t += 1; while (t > 1) { if (t % 2) { res = 'R' + res; } else { res = 'L' + res; } t /= 2; } cout << res << '\n'; } return 0; }