If values used in option two never change use this version while if values will change over time use option one.
Which is better and faster LINQ Query or Formula?
Hobbyist_programmer
621
Reputation points
Hallo,
I just want to know the expert opinion on something I am planning to do. I have to write a method to determine cost of multiple objects . I can do this in two ways
- Make a table with list of items and costs ( so basically I get cost data from a table - aprox 2000 rows & 3 columns) then use LINQ to list of objects
- Create a polynomial function to calculate cost of an item ( at lease 10-20 lines of code depend on item)
what is better and faster?
Thanks
2 answers
Sort by: Most helpful
-
-
Hobbyist_programmer 621 Reputation points
2021-03-11T12:38:07.627+00:00 is there any performance difference between these two?