using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication1
{
class
Program
{
static
void Main(string[]
args)
{
Console.WriteLine("Enter limit");
int
limit = Convert.ToInt16(Console.ReadLine());
int
PRODUCT = 1;
for
(int i = 1; i <= limit; i++)
{
PRODUCT = PRODUCT *
i;
}
Console.WriteLine("The product is :" +
PRODUCT.ToString());
Console.WriteLine("end");
Console.ReadLine();
}
}
}
No comments:
Post a Comment