Use an order by descending clause and call FirstOrDefault() (from p in obj1 group p by p. ObjID into g let totalSum = g. Sum(p => p.
ObjPrice) orderby totalSum descending select new { MyObjectID = g. Key, totalSum }).FirstOrDefault().
Use an order by descending clause and call FirstOrDefault(). (from p in obj1 group p by p. ObjID into g let totalSum = g.
Sum(p => p. ObjPrice) orderby totalSum descending select new { MyObjectID = g. Key, totalSum }).FirstOrDefault().
– Daniel A. White Mar 23 at 1:05 +1 This should work fine. – Pandincus Mar 23 at 1:06 +1 I agree, this should work fine :) – Ian Jasper Bardoquillo Mar 23 at 1:25 1 is { MyObjectId = g.
Key, totalSum } a legal construct? Should totalSum get assigned to a property? Just asking as I've never seen that before.
– Matt Greer Mar 23 at 1:35 @Matt Greer It works in C#3 (just tried in LINQPad ;-) -- same as ..., totalSum = totalSum } but pure voodoo if you ask me. Also works on compound identifiers (g. Key, e.g. -> takes last identifier -- Key here -- as key).
– pst Mar 23 at 2:21.
Select new { MyObjectID = g. Group p by p. Let totalSum = g.
I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.