結果
問題 |
No.499 7進数変換
|
ユーザー |
|
提出日時 | 2024-03-31 11:32:08 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 339 bytes |
コンパイル時間 | 4,105 ms |
コンパイル使用メモリ | 251,104 KB |
最終ジャッジ日時 | 2025-02-20 16:11:38 |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 1 WA * 30 |
ソースコード
#include <bits/stdc++.h> #include <atcoder/all> using namespace std; using namespace atcoder; using ll = long long; using ld = long double; ll N; string ans; int main() { cin >> N; while (N > 0) { ans += '0' + N % 7; N /= 7; } if (N == 0) ans = "0"; reverse(ans.begin(), ans.end()); cout << ans << endl; return 0; }