結果
| 問題 | No.392 2分木をたどれ |
| コンテスト | |
| ユーザー |
ngtkana
|
| 提出日時 | 2020-03-21 12:04:28 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 444 bytes |
| 記録 | |
| コンパイル時間 | 1,443 ms |
| コンパイル使用メモリ | 211,728 KB |
| 実行使用メモリ | 7,968 KB |
| 最終ジャッジ日時 | 2026-06-09 03:25:19 |
| 合計ジャッジ時間 | 3,620 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 3 |
ソースコード
#include<bits/stdc++.h>
using lint=long long;
int main(){
std::cin.tie(nullptr);std::ios_base::sync_with_stdio(false);
std::cout.setf(std::ios_base::fixed);std::cout.precision(15);
lint q;std::cin>>q;
while(q--){
lint x;std::cin>>x;
std::string ans;
while(x){
ans.push_back(x%2?'L':'R');
x=(x-1)/2;
}
std::cout<<std::string(ans.rbegin(),ans.rend())<<'\n';
}
}
ngtkana