title: Create new list in nested list C#
body: <p>Anyone know how to add new list into another list, the new list cannot be predefined.</p>
  
  <p>For example, after get user input, I will do the following</p>
  
  <pre><code>List&lt;List&lt;string&gt;&gt; ListA = new List&lt;List&lt;string&gt;&gt;();
  
  foreach (List&lt;string&gt; subList in ListA)
  {
       foreach (var value in subList)
       {
            if(value != INPUT)
            {
                  // ListA needs to creates a new list with value INPUT
            }
       }
  }
  </code></pre>