Search⌘ K

Solved Problem - Prime Factorization

Explore the process of prime factorization by learning how to determine all prime factors of a given integer efficiently. Understand the algorithmic approach of dividing numbers to identify prime factors and how this concept applies within competitive programming using C++.

Problem statement

Given an integer, NN, print all the prime factors of NN.

Input format

A single line of input contains an integer NN (1N1010)(1 \leq N \leq 10^{10}).

Output format

Print all the prime factors of NN.


Sample

Input 1: `

24

Output 1:

2 3

Input 2:

207

Output 2:

3 23

Explanation

24=23×324 = 2^{3} \times 3 ...