Optimizing the comparison of a variable with multiple options in C#

added by Paul Wheeler
10/6/2017 1:31:56 PM

1 Kicks, 413 Views

Yesterday, I wrote about my thoughts around optimising the comparison of a variable with multiple options and how I prefer to optimize for readability over theoretical or potential performance issues. After some discussion on twitter about how my sample code might be optimized I thought it was worth doing some proper analysis.


0 comments