For19. An integer N (>0) is given. Find a work
\(N! = 1 \cdot 2 \cdot ... \cdot N \)
(N-factorial). To avoid an integer overflow, calculate this product using a real variable and print it as a real number.

Solution in Python 3:

import random

N = random.randrange(1,15)
print('N = ', N)

F = 1.0
for i in range(1,N+1):
F *= i
print(i," : ", F)
print("Result:",F)