Prime Factorization Problem

Prime Factorization Problem — ExecCode Easy DSA Practice

Solve the Prime Factorization problem on ExecCode. Free online easy DSA practice in Numbers & Math Logic. Write and run code in Java, C++, Python — no signup required to run.

Problem description

Description You are given the input needed to solve Prime Factorization. Your task is to compute the required answer and return prime factors space-separated. Integer n.

Examples

Input {"n": 12}; Output 2 2 3. Input {"n": 35}; Output 5 7. Input {"n": 100}; Output 2 2 5 5

Constraints

2 <= n <= 10^7

Practice Prime Factorization free on ExecCode. Browse DSA problems, topic map, and placement guides.