Hello Friends, In this tutorial we are going to learn Lambda Expression. We have already familiar with Delegates and Anonymous Function.

## After completing this tutorial you will be able to understand:

• What is Lambda Expression?
• How to use Lambda Expression in C#?

## Introduction:

The term lambda is not new It has derived from the mathematical term lambda calculus. Lambda expression is a simpler way to define Anonymous method. Lambda operator (=>) is used to define Lambda expression. The => operator can be read as “goes to” or “becomes”. The left side of => operator specifies the lambda expression and right side of => operator specifies the expression or code block.

### The expression for defining Lambda Expression:

`(input parameters) => Statement or Code Block`

### Example for defining Lambda Expression:

`x => x * 2`

### How to find Even Number from a list of Integer:

```
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace LambdaExpressionExample
{
public class Program
{
public static void Main(string[] args)
{
List<int> lstIntegers = new List<int>() { 1, 2, 3, 4, 5, 6 };
List<int> lstEvenNumbers = lstIntegers.FindAll(iNumber => (iNumber % 2) == 0);

foreach (var vNum in lstEvenNumbers)
{
Console.Write("{0} ", vNum);
}
Console.WriteLine();
}
}
}```

### Order a list of the string:

```using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace LambdaExpressionExample2
{
public class Technology
{
public string LanguageName { get; set; }
}
public class Program
{
public string LanguageName { get; set; }
public static void Main(string[] args)
{
List<Technology> lstTechnology = new List<Technology>() {
new Technology { LanguageName = "C#"},
new Technology { LanguageName = "PHP"},
new Technology { LanguageName = "ASP.NET" },
new Technology { LanguageName = "SQL Server" },
new Technology { LanguageName = "Java" },
new Technology { LanguageName = "MY SQL" },
};
var sortedTechnologies = lstTechnology.OrderByDescending(x => x.LanguageName);
foreach (var item in sortedTechnologies)
{
Console.WriteLine(string.Format("{0}", item.LanguageName));
}
}
}
}```

### Conclusion:

Hope you are now clear about my this tutorial. I would like to have your Comments, Feedback and Suggestions.

Thank You.

### Explore post tags

• naturally like your web-site but you need to check the spelling on quite a few of your posts. A number of them are rife with spelling problems and I find it very bothersome to tell the truth nevertheless I’ll definitely come back again.

• Hi, i read your blog from time to time and i own a similar one and i was just wondering if you get a lot of spam remarks? If so how do you stop it, any plugin or anything you can suggest? I get so much lately it’s driving me crazy so any help is very much appreciated.

• Nice post. I learn something new and challenging on blogs I stumbleupon everyday. It’s always useful to read trik kalahkan agen togel content from other writers and practice a little something from other websites.

• Thanks so much for this post. ItÃ­s well concocted and extensive. We just formed our own, and are still trying to improve it to make it pretty.

• Spot on with this write-up, I truly believe this amazing site needs much more attention. game online mesin slot I’ll probably be back again to read more, thanks for the information!

• Way cool! Some very valid points! I appreciate you writing this post plus the rest of the site is really good.

• Hmm is anyone else encountering problems with the pictures on this blog loading? I’m trying to determine if its a problem on my end or if it’s the blog. Any feed-back would be greatly appreciated.

• Im thankful for the post. Really Great.

• I really enjoy the article post. Great.

• wow, awesome blog.Thanks Again.

• Very good blog article.Really looking forward to read more.

• Hi there, I found your web site via Google while looking for a related topic, your web site came up, it looks great. I have bookmarked it in my google bookmarks.

• Really informative post.Really looking forward to read more. Cool.

• May I just say what a relief to discover somebody who genuinely understands daftar game casino terhebat This web site is something that is needed on the internet, someone with a little originality!

• Hello there, I discovered your website by the use of Google even as searching for a related subject, your web site came up, it seems great. I’ve bookmarked it in my google bookmarks.

• Im thankful for the article.Really looking forward to read more. Keep writing.

• Thanks a lot for the blog.Really thank you! Cool.

• Im grateful for the blog article.Much thanks again. Really Great.

• Really appreciate you sharing this post. Much obliged.

• It’s best to take part in a contest for the most effective blogs on the web. I will advocate this web site!

• Im thankful for the article post.Really looking forward to read more. Really Great.

• Major thankies for the post.Really looking forward to read more. Really Great.

• Thanks for the blog.Really looking forward to read more. Keep writing.

• Thanks for sharing, this is a fantastic article.Really looking forward to read more. Much obliged.

• Muchos Gracias for your article post.Really looking forward to read more. Much obliged.

• I appreciate you sharing this post. Much obliged.

• I loved your blog article.Really thank you! Really Cool.

• Looking forward to reading more. Great blog.Really thank you! Keep writing.

• I precisely wished to say thanks yet again. I’m not certain the things that I would’ve taken care of in the absence of these ideas documented by you concerning my subject matter. It truly was an absolute hard circumstance for me, but seeing your specialised approach you solved it took me to cry with delight. I’m just thankful for this support and then wish you recognize what a great job your are doing teaching the mediocre ones through the use of your webblog. I’m certain you haven’t met all of us.

• You made some nice points there. I looked on the internet for the topic and found most persons will consent with your blog.

• I think this is a real great article.Thanks Again. Keep writing.

• Best view i have ever seen !

• wow, awesome article.Thanks Again. Cool.

• Very nice content here.I really like this blog so much a lot of content and very informative for everyone.Thanks.เกมยิงปลา

• This is one awesome blog article.Really thank you! Awesome.

• Can I simply just say what a relief to uncover someone that really knows cara menang slot This site is something that is required on the internet, someone with a little originality!

• Keep working ,great job!

• Fantastic article post.Thanks Again.

• Really enjoyed this blog post.Really thank you! Cool.

• The other day, while I was at work, my sister stole my iphone and tested to see if it can survive a thirty foot drop, just so she can be a youtube sensation. My iPad is now broken and she has 83 views. I know this is totally off topic but I had to share it with someone!

• Just want to say your article is as astounding. The clarity in your post is just cool and i could assume you’re an expert on this subject. Well with your permission allow me to grab your RSS feed to keep updated with forthcoming post. Thanks a million and please continue the enjoyable work.

• Im thankful for the post.Really looking forward to read more. Really Great.

• I am so grateful for your post. Want more.

• Im grateful for the article.Really looking forward to read more. Great.

• I am so grateful for your post. Fantastic.

• I really enjoy the blog post.Really looking forward to read more.

• Thanks-a-mundo for the article post.Really looking forward to read more. Really Great.

• Thanks-a-mundo for the blog article.Much thanks again. Keep writing.

• Enjoyed every bit of your blog.Really looking forward to read more. Really Great.

• Thanks for sharing, this is a fantastic article.Much thanks again. Awesome.

• Very good post.Really thank you! Really Cool.

• Thanks again for the article post.Thanks Again. Fantastic.

• Major thankies for the blog. Great.

• Hi there, You’ve performed an incredible job. I will definitely digg it and in my opinion suggest to my friends. I am sure they will be benefited from this web site.

• A round of applause for your post.Really looking forward to read more. Cool.

• I’ve always had internet explorer and I never used anything else. What can google chrome and firefox do that internet explorer cant?.

• I think this is a real great post. Will read on…

• I cannot thank you enough for the blog article.Really thank you!

• Enjoyed every bit of your article post.Really thank you! Will read on…

• Can I simply just say what a relief to discover somebody who actually knows rumus jitu togel This website is something that is required on the internet, someone with a bit of originality!

• Very good article. Cool.

• Thank you ever so for you blog post. Will read on…

• Really appreciate you sharing this post.Much thanks again.

• I have been browsing on-line more than three hours nowadays, yet I by no means found any attention-grabbing article like yours. It is pretty value sufficient for me. Personally, if all website owners and bloggers made good content as you did, the web might be a lot more useful than ever before.

• Thank you ever so for you blog post.Thanks Again. Cool.

• Very good article post.Really looking forward to read more. Really Great.

• Say, you got a nice blog post.Much thanks again. Keep writing.

• I think this is a real great post.Much thanks again. Want more.

• Major thankies for the article post.Really looking forward to read more. Really Great.