From the course: .NET Essentials: Working with LINQ

Unlock this course with a free trial

Join today to access over 22,600 courses taught by industry experts.

Solution: Write select expressions

Solution: Write select expressions - .NET Tutorial

From the course: .NET Essentials: Working with LINQ

Solution: Write select expressions

(upbeat music) - [Narrator] I hope you had fun working on the Code Challenge. Here's my results. Remember your solution may be different from mine. You'll find my solution in the Code Challenges folder. So I started online too by calling get colors, which returns a list of web color. Then I sorted by green value. That was one of the optional requirements is that it looks this there's the green values, the middle value in this formula. And what I wanted to do is have the highest green values first in the sorter, so I said, order by color dyed green value. And then I used to sending the descending keyword to reverse this order. Now I know I haven't talked about this yet, but that's how you reverse the store order. Then I have two columns in my results, color name and formula color name is created here and the anonymous type on this first parameter, I'm using a string interpretation. So I have a string I'm generating…

Contents