Condition of the problem:
for this natural n calculate the amount of 1! +2! +2!+...+n!. In solving this problem, only one cycle can be used. It is forbidden to use the mathematical library in this task.
n = int span> ( input ()) n = 1 sum = 0 for a in range ( 1 , n+ 1 ): for b in range ( 1 , a + 1 ): n = n * b sum += " N print ( sum ) , however, my solution does not come out. Tell me how to solve correctly?
question@mail.ru
·