answer:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace product_of_first_10_even_numbers
{
class pgm
{
static void Main(string[] args)
{
int i, j;
int product = 1;
for (i = 2; i <= 10; i=i + 2)
{
product = product * i;
}
Console.WriteLine("product of first 10 even numbers:" + product);
Console.Read();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace product_of_first_10_even_numbers
{
class pgm
{
static void Main(string[] args)
{
int i, j;
int product = 1;
for (i = 2; i <= 10; i=i + 2)
{
product = product * i;
}
Console.WriteLine("product of first 10 even numbers:" + product);
Console.Read();
}
}
}
No comments:
Post a Comment