結果
| 問題 |
No.2087 基数の変換
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-09-30 21:29:24 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 50 ms / 2,000 ms |
| コード長 | 328 bytes |
| コンパイル時間 | 310 ms |
| コンパイル使用メモリ | 82,040 KB |
| 実行使用メモリ | 57,124 KB |
| 最終ジャッジ日時 | 2024-12-22 22:24:22 |
| 合計ジャッジ時間 | 4,166 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 51 |
ソースコード
from collections import *
from itertools import *
from functools import *
from heapq import *
import sys,math
input = sys.stdin.readline
N = int(input())
M = int(input())
if M==0:
print(0)
exit()
res = M
b = N
tmp = []
while res>0:
t = res%b
tmp.append(str(t))
res = res//b
tmp.reverse()
print(''.join(tmp))