• Advertisement


This topic is now archived and is closed to further replies.

IFs or Case is there a better way?

This topic is 5684 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

If there are only a couple of conditions I''d use if, but if there are a lot I''d use case.

The compiler can optimise large switch blocks into a jump-table, which is fast.

Helpful links:
How To Ask Questions The Smart Way | Google can help with your question | Search MSDN for help with standard C or Windows functions

Share this post

Link to post
Share on other sites

  • Advertisement