C# - match many cases in a single run
<p>So the case is this:</p>

<p>The user can provide a group of strings for a propert. ex: </p>

<pre><code>DaysNeeded ="Sunday,Tuesday,Friday,Saturday";
</code></pre>

<p>In the actual UI, the days of the week are available as check boxes. I'm trying to provide a way so that the user can also set the days needed in the code behind through a property.</p>

<p>Now my query is, which strategy is the best way to execute certain pieces of code that are respective to the days that the user have provided. Meaning, the DaysNeeded property has sunday,Tuesday, Friday and Saturday. Each day has certain piece of code  to be executed. If i have to have a forloop with a switch case for each day of the week, i feel it would cost more as i have to run the for loop, the number of days the user has given. </p>

<p>Is there a way that i can run a single code that matches all the set of days the user has given and run the respective code pieces?</p>

<p>Please let me know if I'm not clear with my query.</p>
