Given an integer , can you determine its prime factors?
The input will contain a single integer ().
Print the prime factors of in the following format:
N = f1 ^ p1 * f2 ^ p2 * f3 ^ p3 ...
For example, when , you will print:
20580 = 2 ^ 2 * 3 ^ 1 * 5 ^ 1 * 7 ^ 3
Note that the prime factors are in ascending order. If a prime number is not a prime factor of , then the prime number is omitted from the expression.
Input | Output |
---|---|
20580 | 20580 = 2 ^ 2 * 3 ^ 1 * 5 ^ 1 * 7 ^ 3 |