SHARE
TWEET

BigFactorial

Katina_ Jun 25th, 2019 53 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. using System;
  2. using System.Numerics;
  3.  
  4. namespace BigFactorial
  5. {
  6.     class Program
  7.     {
  8.         static void Main(string[] args)
  9.         {
  10.             int number = int.Parse(Console.ReadLine());
  11.             BigInteger factorial = 1;
  12.  
  13.             for (int i = 2; i <= number; i++)
  14.             {
  15.                 factorial *= i;
  16.             }
  17.  
  18.             Console.WriteLine(factorial);
  19.         }
  20.     }
  21. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top