So I have this program and need it to write the output as "96 is 2^5 x 3^1" instead of 2x2x2x2x2x3.

```
    int main() {

        int i, n;

        // Get the user input.
        printf("Please enter a number.\n");
        scanf("%d", &n);

        // Print header.
        printf("The prime factorization of %d is ", n);

        // Loop through, finding prime factors.
        int cur_factor = 2;
        while (cur_factor < n) {

            // Found a factor.
            if (n%cur_factor == 0) {
                printf("%d x ", cur_factor);
                n = n/cur_factor;

            }

            // Going to the next possible factor.
            else
                cur_factor++;
        }

        // Prints last factor.
        printf("%d.\n", cur_factor);

        return 0;

```

What do I need to do?
Thanks