<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>C# / Csharp.Net Tutorials</title>
	<atom:link href="http://csharp.net-tutorials.org/feed/" rel="self" type="application/rss+xml" />
	<link>http://csharp.net-tutorials.org</link>
	<description>C#.net Tutorial</description>
	<lastBuildDate>Sat, 10 Mar 2012 12:28:15 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>C# / Csharp datatable to xml example</title>
		<link>http://csharp.net-tutorials.org/datatable-tutorial/datatable-to-xml/c-csharp-datatable-to-xml-example/</link>
		<comments>http://csharp.net-tutorials.org/datatable-tutorial/datatable-to-xml/c-csharp-datatable-to-xml-example/#comments</comments>
		<pubDate>Fri, 15 Jul 2011 06:27:51 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[DataTable to XML]]></category>
		<category><![CDATA[C# datatable to xml]]></category>
		<category><![CDATA[Csharp datatable to xml]]></category>
		<category><![CDATA[datatable to xml]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=590</guid>
		<description><![CDATA[<p>A simple example in csharp / C# to save datatable to xml format. DataTable to xml example </p> using System; using System.Data; public class DataTableToXmlExample { public static void Main() { //adding up a new datatable DataTable dtEmployee = new DataTable(&#34;Employee&#34;); //adding up 3 columns to datatable dtEmployee.Columns.Add(&#34;ID&#34;, typeof(int)); dtEmployee.Columns.Add(&#34;Name&#34;, typeof(string)); dtEmployee.Columns.Add(&#34;Salary&#34;, typeof(double)); //adding up [...]]]></description>
			<content:encoded><![CDATA[<p>A simple example in csharp / C# to save datatable to xml format.<br />
<strong>DataTable to xml example</strong><br />
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 336x280, created 7/15/11 */
google_ad_slot = "4341750559";
google_ad_width = 336;
google_ad_height = 280;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></p>
<pre class="brush: csharp; title: ; notranslate">
using System;
using System.Data;

public class DataTableToXmlExample
{
    public static void Main()
    {
        //adding up a new datatable
        DataTable dtEmployee = new DataTable(&quot;Employee&quot;); 

        //adding up 3 columns to datatable
        dtEmployee.Columns.Add(&quot;ID&quot;, typeof(int));
        dtEmployee.Columns.Add(&quot;Name&quot;, typeof(string));
        dtEmployee.Columns.Add(&quot;Salary&quot;, typeof(double));

        //adding up rows to the datatable
        dtEmployee.Rows.Add(52, &quot;Human1&quot;, 21000);
        dtEmployee.Rows.Add(63, &quot;Human2&quot;, 22000);
        dtEmployee.Rows.Add(72, &quot;Human3&quot;, 23000);
        dtEmployee.Rows.Add(110,&quot;Human4&quot;, 24000);

         //this will save the datatable into employee.xml file
        dtEmployee.WriteXml(@&quot;C:\Test\Employee.xml&quot;);

        Console.WriteLine(&quot;File saved in xml format!&quot;);

        Console.ReadLine();
    }

}
</pre>
<p><script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 336x280, created 7/15/11 */
google_ad_slot = "4341750559";
google_ad_width = 336;
google_ad_height = 280;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/datatable-tutorial/datatable-to-xml/c-csharp-datatable-to-xml-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Csharp / C# DataTable sort example</title>
		<link>http://csharp.net-tutorials.org/datatable-tutorial/datatable-sort/csharp-c-datatable-sort-example/</link>
		<comments>http://csharp.net-tutorials.org/datatable-tutorial/datatable-sort/csharp-c-datatable-sort-example/#comments</comments>
		<pubDate>Thu, 14 Jul 2011 13:37:25 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[DataTable Sort]]></category>
		<category><![CDATA[C# DataTable select]]></category>
		<category><![CDATA[C# Datatable sort]]></category>
		<category><![CDATA[Csharp DataTable]]></category>
		<category><![CDATA[DataTable sort]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=584</guid>
		<description><![CDATA[<p>A quick sort on a datatable using C# / Csharp.</p> <p>DataTable sort example </p> using System; using System.Data; public class DataTableSortExample { public static void Main() { //adding up a new datatable DataTable dtEmployee = new DataTable(&#34;Employee&#34;); //adding up 3 columns to datatable dtEmployee.Columns.Add(&#34;ID&#34;, typeof(int)); dtEmployee.Columns.Add(&#34;Name&#34;, typeof(string)); dtEmployee.Columns.Add(&#34;Salary&#34;, typeof(double)); //adding up rows to the datatable [...]]]></description>
			<content:encoded><![CDATA[<p>A quick sort on a datatable using C# / Csharp.</p>
<p><strong>DataTable sort example</strong><br />
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 336x280, created 7/15/11 */
google_ad_slot = "4341750559";
google_ad_width = 336;
google_ad_height = 280;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></p>
<pre class="brush: csharp; title: ; notranslate">
using System;
using System.Data;

public class DataTableSortExample
{
    public static void Main()
    {
        //adding up a new datatable
        DataTable dtEmployee = new DataTable(&quot;Employee&quot;); 

        //adding up 3 columns to datatable
        dtEmployee.Columns.Add(&quot;ID&quot;, typeof(int));
        dtEmployee.Columns.Add(&quot;Name&quot;, typeof(string));
        dtEmployee.Columns.Add(&quot;Salary&quot;, typeof(double));

        //adding up rows to the datatable
        dtEmployee.Rows.Add(52, &quot;Human1&quot;, 21000);
        dtEmployee.Rows.Add(63, &quot;Human2&quot;, 22000);
        dtEmployee.Rows.Add(72, &quot;Human3&quot;, 23000);
        dtEmployee.Rows.Add(110,&quot;Human4&quot;, 24000);

        // sorting the datatable basedon salary in descending order
        DataRow[] rows=  dtEmployee.Select(string.Empty,&quot;Salary desc&quot;);

        //foreach datatable
        foreach (DataRow row in rows)
        {
Console.WriteLine(row[&quot;ID&quot;].ToString() + &quot;:&quot; + row[&quot;Name&quot;].ToString() + &quot;:&quot; + row[&quot;Salary&quot;].ToString());
        }

        Console.ReadLine();
    }

}
</pre>
<p><strong>Output:</strong><br />
110:Human4:24000<br />
72:Human3:23000<br />
63:Human2:22000<br />
52:Human1:21000<br />
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 336x280, created 7/15/11 */
google_ad_slot = "4341750559";
google_ad_width = 336;
google_ad_height = 280;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/datatable-tutorial/datatable-sort/csharp-c-datatable-sort-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Csharp / C# DataTable Compute example</title>
		<link>http://csharp.net-tutorials.org/datatable-tutorial/datatable-compute/csharp-c-datatable-compute-example/</link>
		<comments>http://csharp.net-tutorials.org/datatable-tutorial/datatable-compute/csharp-c-datatable-compute-example/#comments</comments>
		<pubDate>Thu, 14 Jul 2011 13:20:54 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[DataTable Compute]]></category>
		<category><![CDATA[C# datatable]]></category>
		<category><![CDATA[csharp datatable compute.]]></category>
		<category><![CDATA[dataset]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=579</guid>
		<description><![CDATA[<p>Quickly understand the use of compute in datatable. DataTable Compute Example </p> using System; using System.Data; public class DataTableComputeExample { public static void Main() { //adding up a new datatable DataTable dtEmployee = new DataTable(&#34;Employee&#34;); //adding up 3 columns to datatable dtEmployee.Columns.Add(&#34;ID&#34;, typeof(int)); dtEmployee.Columns.Add(&#34;Name&#34;, typeof(string)); dtEmployee.Columns.Add(&#34;Salary&#34;, typeof(double)); //adding up rows to the datatable dtEmployee.Rows.Add(52, &#34;Human1&#34;, [...]]]></description>
			<content:encoded><![CDATA[<p>Quickly understand the use of compute in datatable.<br />
<strong>DataTable Compute Example</strong><br />
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script></p>
<pre class="brush: csharp; title: ; notranslate">
using System;
using System.Data;

public class DataTableComputeExample
{
    public static void Main()
    {
        //adding up a new datatable
        DataTable dtEmployee = new DataTable(&quot;Employee&quot;); 

        //adding up 3 columns to datatable
        dtEmployee.Columns.Add(&quot;ID&quot;, typeof(int));
        dtEmployee.Columns.Add(&quot;Name&quot;, typeof(string));
        dtEmployee.Columns.Add(&quot;Salary&quot;, typeof(double));

        //adding up rows to the datatable
        dtEmployee.Rows.Add(52, &quot;Human1&quot;, 21000);
        dtEmployee.Rows.Add(63, &quot;Human2&quot;, 22000);
        dtEmployee.Rows.Add(72, &quot;Human3&quot;, 23000);
        dtEmployee.Rows.Add(110,&quot;Human4&quot;, 24000);

        Console.Write(&quot;Employee Count:&quot;);
        Console.WriteLine(dtEmployee.Compute(&quot;Count(ID)&quot;, string.Empty));

        Console.Write(&quot;Maximum Salary:&quot;);
        Console.WriteLine(dtEmployee.Compute(&quot;Max(Salary)&quot;,string.Empty));

        Console.Write(&quot;Minimum Salary:&quot;);
        Console.WriteLine(dtEmployee.Compute(&quot;Min(Salary)&quot;, string.Empty));

        Console.Write(&quot;Average Salary:&quot;);
        Console.WriteLine(dtEmployee.Compute(&quot;Avg(Salary)&quot;, string.Empty));

        Console.Write(&quot;Sum Salary:&quot;);
        Console.WriteLine(dtEmployee.Compute(&quot;Sum(Salary)&quot;, string.Empty));

        Console.ReadLine();
    }

}
</pre>
<p><strong>Output:</strong></p>
<p>Employee Count:4<br />
Maximum Salary:24000<br />
Minimum Salary:21000<br />
Average Salary:22500<br />
Sum Salary:90000<br />
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script></p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/datatable-tutorial/datatable-compute/csharp-c-datatable-compute-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>C# / Csharp Foreach DataTable example</title>
		<link>http://csharp.net-tutorials.org/datatable-tutorial/foreach-datatable/c-csharp-foreach-datatable/</link>
		<comments>http://csharp.net-tutorials.org/datatable-tutorial/foreach-datatable/c-csharp-foreach-datatable/#comments</comments>
		<pubDate>Thu, 14 Jul 2011 12:57:35 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[foreach datatable]]></category>
		<category><![CDATA[C# foreach datatable]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=571</guid>
		<description><![CDATA[<p>Quick way to foreach datatable using C# / Csharp example. </p> <p>Example:</p> using System; using System.Data; public class ForEachDataTableExample { public static void Main() { //adding up a new datatable DataTable dtEmployee = new DataTable(&#34;Employee&#34;); //adding up 3 columns to datatable dtEmployee.Columns.Add(&#34;ID&#34;, typeof(int)); dtEmployee.Columns.Add(&#34;Name&#34;, typeof(string)); dtEmployee.Columns.Add(&#34;Salary&#34;, typeof(double)); //adding up rows to the datatable dtEmployee.Rows.Add(52, &#34;Human1&#34;, [...]]]></description>
			<content:encoded><![CDATA[<p>Quick way to foreach datatable using C# / Csharp example.<br />
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script></p>
<p><strong>Example:</strong></p>
<pre class="brush: csharp; title: ; notranslate">
using System;
using System.Data;

public class ForEachDataTableExample
{
    public static void Main()
    {
        //adding up a new datatable
        DataTable dtEmployee = new DataTable(&quot;Employee&quot;); 

        //adding up 3 columns to datatable
        dtEmployee.Columns.Add(&quot;ID&quot;, typeof(int));
        dtEmployee.Columns.Add(&quot;Name&quot;, typeof(string));
        dtEmployee.Columns.Add(&quot;Salary&quot;, typeof(double));

        //adding up rows to the datatable
        dtEmployee.Rows.Add(52, &quot;Human1&quot;, 21000);
        dtEmployee.Rows.Add(63, &quot;Human2&quot;, 22000);
        dtEmployee.Rows.Add(72, &quot;Human3&quot;, 23000);
        dtEmployee.Rows.Add(110,&quot;Human4&quot;, 24000);

        //foreach datatable
        foreach (DataRow row in dtEmployee.Rows)
        {
Console.WriteLine(row[&quot;ID&quot;].ToString() + &quot;:&quot; + row[&quot;Name&quot;].ToString() + &quot;:&quot; + row[&quot;Salary&quot;].ToString());
        }

        Console.ReadLine();
    }

}
</pre>
<p><strong>Output:</strong><br />
52:Human1:21000<br />
63:Human2:22000<br />
72:Human3:23000<br />
110:Human4:24000<br />
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script></p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/datatable-tutorial/foreach-datatable/c-csharp-foreach-datatable/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Csharp / C# Yield return example</title>
		<link>http://csharp.net-tutorials.org/miscellaneous/csharp-c-yield-return-example/</link>
		<comments>http://csharp.net-tutorials.org/miscellaneous/csharp-c-yield-return-example/#comments</comments>
		<pubDate>Thu, 07 Jul 2011 11:21:14 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=557</guid>
		<description><![CDATA[<p>C# yield return example.</p> <p>Example:</p> using System; using System.Collections.Generic; class ExampleYieldReturn { static void Main(string[] args) { //with every call it goes to where it left till it encounters yield return foreach(int n in GetNumbers()) { Console.WriteLine(n); } Console.ReadLine(); } public static IEnumerable&#60;int&#62; GetNumbers() { Console.WriteLine(&#34;Print number 52&#34;); yield return 52; // will go back [...]]]></description>
			<content:encoded><![CDATA[<p>C# yield return example.</p>
<table border="0" >
<tr>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
</tr>
</table>
<p><strong>Example:</strong></p>
<pre class="brush: csharp; title: ; notranslate">
using System;
using System.Collections.Generic;

    class ExampleYieldReturn
    {
        static void Main(string[] args)
        {
            //with every call it goes to where it left till it encounters yield return
            foreach(int n in GetNumbers())
            {
                Console.WriteLine(n);
            }

            Console.ReadLine();
        }

    public static IEnumerable&lt;int&gt; GetNumbers()
        {
            Console.WriteLine(&quot;Print number 52&quot;);
            yield return 52; // will go back to the caller ie foreach

            Console.WriteLine(&quot;Print number 63&quot;);
            yield return 63;// again will go back to the caller ie foreach

            Console.WriteLine(&quot;Print number 72&quot;);
            yield return 72;// again will go back to the caller ie foreach

        }

    }
</pre>
<p><strong>Output:</strong><br />
Print number 52<br />
52<br />
Print number 63<br />
63<br />
Print number 72<br />
72</p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/miscellaneous/csharp-c-yield-return-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Csharp / C# send email example</title>
		<link>http://csharp.net-tutorials.org/miscellaneous/csharp-c-send-email-example/</link>
		<comments>http://csharp.net-tutorials.org/miscellaneous/csharp-c-send-email-example/#comments</comments>
		<pubDate>Thu, 07 Jul 2011 10:06:04 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=546</guid>
		<description><![CDATA[<p>Csharp / C# send email a very simple example.</p> <p>Example:</p> using System; using System.Net.Mail; class Program { static void Main(string[] args) { try { MailMessage mail = new MailMessage(); SmtpClient SmtpServer = new SmtpClient(&#34;smtp.net-tutorials.org&#34;); mail.From = new MailAddress(&#34;human@net-tutorials.org&#34;); mail.To.Add(&#34;being@net-tutorials.org&#34;); mail.Subject = &#34;Being Human&#34;; mail.Body = &#34;We are all humans! So come out of our way [...]]]></description>
			<content:encoded><![CDATA[<p>Csharp / C# send email a very simple example.</p>
<p><strong>Example:</strong></p>
<pre class="brush: csharp; title: ; notranslate">
using System;
using System.Net.Mail;

    class Program
    {
        static void Main(string[] args)
        {
            try
            {

                MailMessage mail = new MailMessage();
                SmtpClient SmtpServer = new SmtpClient(&quot;smtp.net-tutorials.org&quot;);

                mail.From = new MailAddress(&quot;human@net-tutorials.org&quot;);
                mail.To.Add(&quot;being@net-tutorials.org&quot;);
                mail.Subject = &quot;Being Human&quot;;
                mail.Body = &quot;We are all humans! So come out of our way to help mankind.&quot;;
                SmtpServer.Send(mail);
            }
            catch (Exception ex)
            {
                Console.WriteLine(&quot;Seems some problem!&quot;);
            }

            Console.WriteLine(&quot;Email sent successfully!&quot;);
            Console.ReadLine();
        }

    }
</pre>
<table border="0" >
<tr>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
</tr>
</table>
<p><strong>Output:</strong><br />
Email sent successfully!</p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/miscellaneous/csharp-c-send-email-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Csharp / C# Linq Aggregate example</title>
		<link>http://csharp.net-tutorials.org/linq-to-objects/linq-aggregate/csharp-c-linq-aggregate-example/</link>
		<comments>http://csharp.net-tutorials.org/linq-to-objects/linq-aggregate/csharp-c-linq-aggregate-example/#comments</comments>
		<pubDate>Fri, 17 Jun 2011 13:23:07 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linq Aggregate]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=498</guid>
		<description><![CDATA[<p>Example:</p> <p>using System; using System.Linq; using System.Collections.Generic;</p> <p> class LinqToListExample { public static void Main(string[] args) {</p> <p> int[] nums = { 1,2,3,4 };</p> <p> var resutls = nums.Aggregate((n1,n2)=> n1 + n2);</p> <p> // step1 n1 = 1, n2 = 2 => n1= (1+2) ie now n1 = 3 // step2 n1 = 3(output from [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Example:</strong></p>
<p>using System;<br />
using System.Linq;<br />
using System.Collections.Generic;</p>
<p>   class LinqToListExample<br />
    {<br />
      public  static void Main(string[] args)<br />
       {</p>
<p>           int[] nums = { 1,2,3,4 };</p>
<p>           var resutls = nums.Aggregate((n1,n2)=> n1 + n2);</p>
<p>           // step1 n1 = 1, n2 = 2 => n1= (1+2) ie now n1 = 3<br />
           // step2 n1 = 3(output from 1st step) ,n2 = 3(third value in array) => n1 = (3+3) ie now n1 = 6<br />
           // step3 n1 = 6(output from 2nd step) ,n2 = 4(fourth value in array) => n1 = (6+4) ie now n1 = 10 (Answer)<br />
           Console.WriteLine(&#8220;The aggregate answer: &#8221; + resutls);</p>
<p>           Console.ReadLine();</p>
<p>        }<br />
    }</p>
<table border="0" >
<tr>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
</tr>
</table>
<p><strong>Output:</strong><br />
The aggregate answer: 10</p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/linq-to-objects/linq-aggregate/csharp-c-linq-aggregate-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Csharp / C# Linq Average example</title>
		<link>http://csharp.net-tutorials.org/linq-to-objects/linq-average/csharp-c-linq-average-example/</link>
		<comments>http://csharp.net-tutorials.org/linq-to-objects/linq-average/csharp-c-linq-average-example/#comments</comments>
		<pubDate>Fri, 17 Jun 2011 13:22:38 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linq Average]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=496</guid>
		<description><![CDATA[<p>Example:</p> <p>using System; using System.Linq; using System.Collections.Generic;</p> <p> class LinqAverageExample { public static void Main(string[] args) {</p> <p> int[] nums = { 51,52,53,63,72,110 };</p> <p> var resutls = nums.Average(n => n);</p> <p> Console.WriteLine(&#8220;The maximum number in the array: &#8221; + resutls);</p> <p> Console.ReadLine();</p> <p> } }</p> <p>Output: The maximum number in the array: 66.8333333333333</p> [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Example:</strong></p>
<p>using System;<br />
using System.Linq;<br />
using System.Collections.Generic;</p>
<p>   class LinqAverageExample<br />
    {<br />
      public  static void Main(string[] args)<br />
       {</p>
<p>           int[] nums = { 51,52,53,63,72,110 };</p>
<p>           var resutls = nums.Average(n => n);</p>
<p>           Console.WriteLine(&#8220;The maximum number in the array: &#8221; + resutls);</p>
<p>           Console.ReadLine();</p>
<p>        }<br />
    }</p>
<table border="0" >
<tr>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
</tr>
</table>
<p><strong>Output:</strong><br />
The maximum number in the array: 66.8333333333333</p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/linq-to-objects/linq-average/csharp-c-linq-average-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Csharp / C# Linq Max example</title>
		<link>http://csharp.net-tutorials.org/linq-to-objects/linq-max/csharp-c-linq-max-example/</link>
		<comments>http://csharp.net-tutorials.org/linq-to-objects/linq-max/csharp-c-linq-max-example/#comments</comments>
		<pubDate>Fri, 17 Jun 2011 13:22:08 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linq Max]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=494</guid>
		<description><![CDATA[<p>Example:</p> <p>using System; using System.Linq; using System.Collections.Generic;</p> <p> class LinqMaxExample { public static void Main(string[] args) {</p> <p> int[] nums = { 51,52,53,63,72,110 };</p> <p> var resutls = nums.Max(n => n);</p> <p> Console.WriteLine(&#8220;The maximum number in the array: &#8221; + resutls);</p> <p> Console.ReadLine();</p> <p> } }</p> <p>Output: The maximum number in the array: 110</p> [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Example:</strong></p>
<p>using System;<br />
using System.Linq;<br />
using System.Collections.Generic;</p>
<p>   class LinqMaxExample<br />
    {<br />
      public  static void Main(string[] args)<br />
       {</p>
<p>           int[] nums = { 51,52,53,63,72,110 };</p>
<p>           var resutls = nums.Max(n => n);</p>
<p>           Console.WriteLine(&#8220;The maximum number in the array: &#8221; + resutls);</p>
<p>           Console.ReadLine();</p>
<p>        }<br />
    }</p>
<table border="0" >
<tr>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
</tr>
</table>
<p><strong>Output:</strong><br />
The maximum number in the array: 110</p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/linq-to-objects/linq-max/csharp-c-linq-max-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Csharp / C# Linq Min example</title>
		<link>http://csharp.net-tutorials.org/linq-to-objects/linq-min/csharp-c-linq-min-example/</link>
		<comments>http://csharp.net-tutorials.org/linq-to-objects/linq-min/csharp-c-linq-min-example/#comments</comments>
		<pubDate>Fri, 17 Jun 2011 13:21:36 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linq Min]]></category>

		<guid isPermaLink="false">http://csharp.net-tutorials.org/?p=492</guid>
		<description><![CDATA[<p>Example:</p> <p>using System; using System.Linq; using System.Collections.Generic;</p> <p> class LinqMinExample { public static void Main(string[] args) {</p> <p> int[] nums = { 51,52,53,63,72,110 };</p> <p> var resutls = nums.Min(n => n);</p> <p> Console.WriteLine(&#8220;The minumum number in the array: &#8221; + resutls);</p> <p> Console.ReadLine();</p> <p> } }</p> <p>Output: The minumum number in the array: 51</p> [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Example:</strong></p>
<p>using System;<br />
using System.Linq;<br />
using System.Collections.Generic;</p>
<p>   class LinqMinExample<br />
    {<br />
      public  static void Main(string[] args)<br />
       {</p>
<p>           int[] nums = { 51,52,53,63,72,110 };</p>
<p>           var resutls = nums.Min(n => n);</p>
<p>           Console.WriteLine(&#8220;The minumum number in the array: &#8221; + resutls);</p>
<p>           Console.ReadLine();</p>
<p>        }<br />
    }</p>
<table border="0" >
<tr>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-3832880870120440";
/* 300x250, created 5/27/11 */
google_ad_slot = "6301664579";
google_ad_width = 300;
google_ad_height = 250;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> 
</script>
</td>
</tr>
</table>
<p><strong>Output:</strong><br />
The minumum number in the array: 51</p>
]]></content:encoded>
			<wfw:commentRss>http://csharp.net-tutorials.org/linq-to-objects/linq-min/csharp-c-linq-min-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
