Python split list at zeros
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/13633901/remove-leading-and-trailing-zeros-from-multidimensional-list-in-python">Remove leading and trailing zeros from multidimensional list in Python</a>  </p>
</blockquote>



<p>if I have a list such as:</p>

<pre><code>my_list = [[1,2,0,1], [1,0,0,1]]
</code></pre>

<p>I want to split this at the zeros and throw them away, so that I end up with something like:</p>

<pre><code>my_list = [[[1, 2], [1]], [[1],[1]]]
</code></pre>

<p>Any help much appreciated.</p>
