Example 12: Write an algorithm and draw a flowchart to calculate
the factorial of a number(N). Verify your result by a trace table by
assuming N = 5.
Hint: The factorial of N is the product of numbers from 1 to N)​