Write a program using linq to find the sum of first 5 prime , Computer Engineering

Class Program

{

static void Main()

{

int[] MyPrimeNumbers = {1,2,3,5,7};

// Use the Count() and Sum() Standard Query Operators to

// compute the count an whole sum simultaeneously

Concole.WriteLine("The sum of first {0} prime number is {1}",

MyPrimeNumbers.Count(), MyPrimeNumbers.Sum());

}

}

 

 

Posted Date: 4/3/2013 2:34:38 AM | Location : United States







Related Discussions:- Write a program using linq to find the sum of first 5 prime , Assignment Help, Ask Question on Write a program using linq to find the sum of first 5 prime , Get Answer, Expert's Help, Write a program using linq to find the sum of first 5 prime Discussions

Write discussion on Write a program using linq to find the sum of first 5 prime
Your posts are moderated
Related Questions
Pass I of the assembler must also generate the intermediate code for the processed statements. Justify your answer. Criteria for selection of a suitable intermediate code form

Q. Compatibility of Sound cards? Compatibility: Sound cards should be compatible at both software and hardware levels with industry standards.  Most software particularly gam

Define seek time and latency time.  The time taken by the head to move to the appropriate cylinder or track is known as seek time. Once the head is at right track, it must wai

Explain the relationship amongst Translated address and Load time address. Translated address: Address assigned through the translator Load time address: Address ass

contributes to violence in our society. Others point out that television contributes to the high level of obesity among children. Now, we may have to add financial problems to the

Back propagation Learning Routine - Aartificial intelligence As with perceptrons, the information in the network is stored in the weights, so the learning problem comes down to

We are trying to figure out how many copy machines we should install in the basement of Stranahan Hall.  Copy machines should be available 24/7.  Students may walk up at any time o

The  most common types are the AWARD,AMI, AND phoenix

A student counted up the number of statements implemented in a program developed for sorting n integers and came up with a recurrence of the form: T(n) = a * n + b + 2T(n/2), an

Currently microcontrollers are embedded within most products, typical uses are in Camera's for auto focus and display drivers, Laser printers to compute fonts and control printing.