题解 | #质数因子#
质数因子
http://www.nowcoder.com/practice/196534628ca6490ebce2e336b47b3607
import math
num = int(input()) sq = int(math.sqrt(num)) find_1 = [] if num == 1: print(1) else: for i in range(2,sq+1): while num % i==0: num = num // i print(i, end=' ')
if num > 2:
print(num)