¡@

Home 

c# Programming Glossary: selectmany

“Nested foreach” vs “lambda/linq query” performance(LINQ-to-Objects)

http://stackoverflow.com/questions/1044236/nested-foreach-vs-lambda-linq-query-performancelinq-to-objects

foreach loops... typically those are represented with SelectMany or a second from clause var query from item in firstSequence..

Can I use extension methods and Linq in .NET 2.0 or 3.0?

http://stackoverflow.com/questions/11346554/can-i-use-extension-methods-and-linq-in-net-2-0-or-3-0

return TResult item public static IEnumerable TResult SelectMany TSource TResult this IEnumerable TSource source Func TSource..

How much is there to LINQ?

http://stackoverflow.com/questions/1418106/how-much-is-there-to-linq

T value return Option T .Some value public static Option U SelectMany T U this Option T m Func T Option U k return m.IsNone Option.. m.IsNone Option U .None k m.Value public static Option V SelectMany T U V this Option T m Func T Option U k Func T U V s return.. V this Option T m Func T Option U k Func T U V s return m.SelectMany x k x .SelectMany y s x y .ToMaybe This would now allow us..

LINQ identity function?

http://stackoverflow.com/questions/1466689/linq-identity-function

syntax. I'm flattening an IEnumerable IEnumerable T with SelectMany x x . My problem is with the lambda expression x x . It looks.. object that I can use instead of x x Something like SelectMany IdentityFunction c# linq lambda linq to objects share improve.. But then type inference wouldn't work so you'd have to do SelectMany Helpers.IdentityFunction Foo which is a lot uglier than x x..

Flatten List in LINQ

http://stackoverflow.com/questions/1590723/flatten-list-in-linq

7 Thanks c# linq list share improve this question Try SelectMany var result iList.SelectMany i i share improve this answer..

Enumerating Collections that are not inherently IEnumerable?

http://stackoverflow.com/questions/1815497/enumerating-collections-that-are-not-inherently-ienumerable

in a form usable by Linq. A comment by Leppie about 'SelectMany in the SO post linked to first above seems like a clue. My experiments.. to first above seems like a clue. My experiments with SelectMany have been well call them disasters. Appreciate any pointers...

Preserving order with LINQ

http://stackoverflow.com/questions/204505/preserving-order-with-linq

elements the order of the matching elements of inner. SelectMany for each element of source selector is invoked and a sequence..

Merging dictionaries in C#

http://stackoverflow.com/questions/294138/merging-dictionaries-in-c-sharp

For instance you could do var result dictionaries.SelectMany dict dict .ToDictionary pair pair.Key pair pair.Value That.. then convert that to a dictionary var result dictionaries.SelectMany dict dict .ToLookup pair pair.Key pair pair.Value .ToDictionary.. duplicate keys. The important bit to my mind is using SelectMany and realising that a dictionary supports iteration over its..

From Eric Lippert's blog: “don't close over the loop variable” [duplicate]

http://stackoverflow.com/questions/3190578/from-eric-lipperts-blog-dont-close-over-the-loop-variable

don't close over the loop variable recursive case use SelectMany to build the new product out of the old one result from seq..

Generating Permutations using LINQ

http://stackoverflow.com/questions/4319049/generating-permutations-using-linq

Linq-to-Sql: recursively get children

http://stackoverflow.com/questions/535436/linq-to-sql-recursively-get-children

Comment only Comment itself Is there anyway to use SelectMany in this situation c# sql linq linq to sql common table expression..

Expressing recursion in LINQ

http://stackoverflow.com/questions/732281/expressing-recursion-in-linq

descendants td or . table descendants td Using IEnumerable SelectMany allows one to call the navigation functions on a collection...

Difference Between Select and SelectMany

http://stackoverflow.com/questions/958949/difference-between-select-and-selectmany

Between Select and SelectMany I've been searching the difference between those two but I.. Many. c# linq to sql linq share improve this question SelectMany flattens queries that return lists of lists. For example public.. PhoneNumber phoneLists people.Select p p.PhoneNumbers SelectMany flattens it to just a list of phone numbers. IEnumerable PhoneNumber..