// using what_next_day;
using System;
namespace my_app
{
class Program
static void Main(string[] args)
// WhatNextDay.run();
Console.WriteLine("N: ");
int n = int.Parse(Console.ReadLine());
int i = 1;
int pre = 1;
int result = 0;
while (i <= n)
pre *= i;
result += pre;
i++;
}
Console.WriteLine($"Ket qua la {result}");