1229 -- An Easy Problem

An Easy Problem

Time Limit:1000MS  Memory Limit:65536K
Total Submit:30 Accepted:20

Description

n mathematics, a prime number (or a prime) is a natural number which has exactly two distinct natural number divisors: 1 and itself. In many cases, it is not enough to know whether a number is prime; sometimes, you need to know its factors.
Every positive integer greater than 1 can be expressed as a product of prime numbers. This factorization is unique and is called the prime factorization. For example, the number 60 can be decomposed into factors 2×2×3×5, each of which is prime. Note that the same prime can appear more than once in the factorization. Note that the same prime can appear more than once in the factorization.
Write a program to display the prime factorization of a number n.

Input

There are multiple test cases. Each case takes one line and contains exact one integer n(2≤n≤2^31-1).
n=0 indicates the end of the input and should not be processed by your program.

Output

For each case, output the prime factorization of a number n.

Sample Input

2
60
0

Sample Output

2
2*2*3*5

Source

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章