結果

問題 No.414 衝動
ユーザー maspymaspy
提出日時 2020-01-27 18:24:36
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 158 ms / 1,000 ms
コード長 308 bytes
コンパイル時間 469 ms
コンパイル使用メモリ 10,644 KB
実行使用メモリ 46,192 KB
最終ジャッジ日時 2023-08-09 13:43:38
合計ジャッジ時間 4,202 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 153 ms
45,884 KB
testcase_01 AC 154 ms
45,960 KB
testcase_02 AC 157 ms
46,096 KB
testcase_03 AC 154 ms
45,904 KB
testcase_04 AC 155 ms
45,904 KB
testcase_05 AC 154 ms
46,060 KB
testcase_06 AC 157 ms
46,192 KB
testcase_07 AC 155 ms
45,904 KB
testcase_08 AC 157 ms
46,068 KB
testcase_09 AC 156 ms
46,028 KB
testcase_10 AC 158 ms
46,072 KB
testcase_11 AC 154 ms
46,060 KB
testcase_12 AC 157 ms
46,168 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

import numpy as np

M = int(read())

x = np.arange(1,10**6 + 10)

div = x[M % x == 0]

div = np.union1d(div, M//div)

if len(div) <= 2:
    print(1, M)
else:
    x = div[1]
    print(x, M//x)
0