結果
問題 |
No.2385 Parse Integer with Radix
|
ユーザー |
![]() |
提出日時 | 2023-07-21 22:00:04 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
RE
|
実行時間 | - |
コード長 | 366 bytes |
コンパイル時間 | 285 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 10,624 KB |
最終ジャッジ日時 | 2024-09-21 23:31:45 |
合計ジャッジ時間 | 1,098 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | RE * 1 |
other | RE * 11 |
ソースコード
import matplotlib.pyplot as plt import math import numpy as np import sys import os # f = open('out.txt') # sys.stdin = f q = int(input()) for _ in range(q): n = input() if n[:2] == "0b": print(int(n[2:], 2)) elif n[:2] == "0o": print(int(n[2:], 8)) elif n[:2] == "0x": print(int(n[2:], 16)) else: print(n)