title: how do I make arrays to be of the same length
body: <p>I have a pickled file that contain a hash with key -> list
  like this</p>
  
  <pre><code>h = { 'two': [1,2], 'three': [3,4,5]}
  </code></pre>
  
  <p>I want to convert the arrays into an array of array, making the arrays of the same length (just filling up with zeros for the shorter arrays)</p>
  
  <p>So the example above I would like to have a result like this</p>
  
  <pre><code>&gt;&gt;&gt; np.asarray([[1,2,0],[3,4,5]])
  array([[1, 2, 0],
         [3, 4, 5]])
  </code></pre>
  
  <p>(I don't care about the keys in the hash, and I also don't care about the order of the arrays).</p>
  
  <p>The first step would be to find the longest array, which I think this code will do for me</p>
  
  <pre><code>m = max(map(len, h.values()))
  </code></pre>
  
  <p>But how do I create the arrays after that?
  I thought numpy.copyto() would be possible;
  copying the original array into a new array filled with zeros and the new length, but it demands arrays of the same shapes.</p>