Thursday, March 2, 2017

Instead of just ordering the cases in a switch statement alphabetically or numerically why don't you order them by likelihood of use?

If the value to be used 90% of the time just shows up first the code doesn't have to crawl past other cases to find what it needs 90% of the time. Get it?

No comments:

Post a Comment