title: Selecting items on a matrix based on indexes given by an array
body: <p>Consider this matrix:</p>
  <pre><code>[0.9, 0.45, 0.4, 0.35],
  [0.4, 0.8, 0.3, 0.25],
  [0.5, 0.45, 0.9, 0.35],
  [0.2, 0.18, 0.8, 0.1],
  [0.6, 0.45, 0.4, 0.9]
  </code></pre>
  <p>and this list:</p>
  <pre><code>[0,1,2,3,3]
  </code></pre>
  <p>I want to create a list that looks like the following:</p>
  <pre><code>[0.9, 0.8, 0.9, 0.1, 0.9]
  </code></pre>
  <p>To clarify, for each row, I want the element of the matrix whose column index is contained in the first array. How can I accomplish this?</p>