Program to print sum of factorial of Odd series in C#

Program to print sum of factorial of Odd series in C# - is the information you are looking for, and in the blog Google News we have provided her, all right in this article titled Program to print sum of factorial of Odd series in C# we will discuss it in full, in addition to the information we have also provided a lot of info about the latest gadgets and a wide range of tips and tricks that according to the gadget you are using, well please continue reading:

Penyanyi : Program to print sum of factorial of Odd series in C#
Judul lagu : Program to print sum of factorial of Odd series in C#
Article Csharp, Article programs,

You can also see our article on:


Program to print sum of factorial of Odd series in C#

C# Program to print sum of factorial of Odd series

Program Statement:
Write a program to display the sum of the following series i.e. sum of the factorial of odd series
1! + 3! + 5! + 7! + 9! + . . . + n!

Solution:
 static void Main(string[] args)
{
int i, j, f,last, sum = 0;
Console.WriteLine("Enter Last value:");
last = Convert.ToInt32(Console.ReadLine());
i = 1;
while (i <= last)
{
f = 1;
j = i;
while (j >= 1)
{
f = f * j;
j--;
}
sum = sum + f;
Console.WriteLine("factorial of " +i+"="+f);
i = i + 2;
}
Console.WriteLine("sum of all factorial = " + sum);
Console.ReadLine();
}




Demikianlah Artikel Program to print sum of factorial of Odd series in C#

Sekian Kunci gitar Program to print sum of factorial of Odd series in C#, mudah-mudahan bisa memberi manfaat untuk anda semua. baiklah, sekian postingan Chord gitar lagu kali ini.

Anda sedang membaca artikel Program to print sum of factorial of Odd series in C# dan artikel ini url permalinknya adalah https://googledoodlenewstoday.blogspot.com/2013/12/program-to-print-sum-of-factorial-of.html Semoga artikel ini bisa bermanfaat.

Tag : , ,
Share on Facebook
Share on Twitter
Share on Google+
Tags :

Related : Program to print sum of factorial of Odd series in C#

0 komentar:

Posting Komentar