✅ best LINQ method to sort after subtracting two properties?
I have a list of objects with two fields, num1 and num2. I would like to subtract num1 by num2 and then sort descending by the resulting value. Can anyone recommend a LINQ method for this?
5 Replies
OrderByDescending?
Oh. Well I feel dumb. Thanks!
wait do you want a return list of just the result of this substraction tho?
ah yeah, maybe i misread the question
that'd be
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.