Differentiate between select() and selectmany() method in linq.
Answer Posted / Anil Tomar
The 'select()' method is used to project each element of a sequence into a new form by applying a transformation function to each element. It returns a new collection containing the result of the projection. The 'selectMany()' method is an extension method that projects each element of a sequence into a flat sequence of values by applying a transformation function to each element, and then concatenating the results together. It does not create any additional collections.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
No New Questions to Answer in this Category !! You can
Post New Questions
Answer Questions in Different Category