Can't get into one thing. I would be very grateful for help.
And so, to the problem: I have a list of Foos objects with inputs a and b that must meet two conditions, for example
db.Foos.Where(foo => foo.a == a && foo.b == b).ToList()
I need to calculate Delta(foo) on the Foos list, and select the object from the list where this delta is minimal.
Delta example:
foo => (a*2 + b) - (foo.a + foo.b)
Actually a question how can I select this object?