title: Compare enum with a List<int>
body: <p>In my database I'm saving numbers. Each number has been allocated to a day. For example 1 equals Monday.</p>
  
  <p>In my C# code I have an enum like:</p>
  
  <pre><code>enum day { Sunday=0, Monday, Tuesday, Wednesday, Thursday, Friday,Saturday  };
  </code></pre>
  
  <p>I want get current day from host and compare it with my database, for checking user access.</p>
  
  <p>What is the best way to compare an enum value with a generic <code>List&lt;int&gt;</code>?</p>
  
  <p>I took a look at this topic <a href="https://stackoverflow.com/questions/5276100/how-to-compare-enum-and-int-values">How to compare enum and int values?</a> but it wasn't useful for me.</p>
  
  <p><strong>UPDATE:</strong> <br>
  I have user access in my program by day and time. I saved the days which can have access to app. the days had saved as integer; so when user wanna login I have to compare integer with enum. because I fetch from database one time, so I have <code>List&lt;int&gt;</code> of days.
  I dont know is there any better way to do it or not?!</p>