結果

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

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 153 ms
46,000 KB
testcase_01 AC 154 ms
45,824 KB
testcase_02 AC 154 ms
45,980 KB
testcase_03 AC 153 ms
46,092 KB
testcase_04 AC 153 ms
46,060 KB
testcase_05 AC 154 ms
45,968 KB
testcase_06 AC 152 ms
46,084 KB
testcase_07 AC 152 ms
46,028 KB
testcase_08 AC 152 ms
46,028 KB
testcase_09 AC 153 ms
46,012 KB
testcase_10 AC 152 ms
46,052 KB
testcase_11 AC 152 ms
46,136 KB
testcase_12 AC 155 ms
46,188 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