title: Storing and retrieving multiple values in a single session
body: <p>I know there are topics with similar heading, but this is kinda different. </p>
  
  <p>First, in order to store multiple values in a single session, I have to use a <code>List</code> whereas I store the list with the values in the session, right ? </p>
  
  <p>If so, when I want to add a value to the List, which is already in the session, then I retrieve the List from the session and add the value. But do I need to assign the List back to the session every time I have added/removed a value from the <code>List</code>? Or ,by default, it gets automatically updated in the session when I manipulate it as it was assigned at first in the session and after that.</p>
  
  <p><strong>UPDATE: providing sample code of my question</strong></p>
  
  <pre><code>public void assignNewID(int currentID)
  {
      if(Session["usersID"] == null)
      {
          Session["usersID"] = new List&lt;int&gt;();
      }
  
      if(currentID != null)
      {
          var list = (List&lt;int&gt;)Session["usersID"];
          list.Add(currentID);
  
          // now should I hereby assign the list back to
          // the session like:
          // Session["usersID"] = list;
          // or it gets automatically updated in the session by default ?
      }
  }
  </code></pre>