title: Create rows of elements based on an array of length values
body: <p>Is there a neat way to split an array into chunks based on an array of lengths?</p>
  <p>Input:</p>
  <pre><code>$start = range(0, 30);
  $length = [3, 7, 2, 12, 6];
  </code></pre>
  <p>Desired Output:</p>
  <pre><code>[
      [0, 1, 2],  // 3
      [4, 5, 6, 7, 8, 9, 10],  // 7
      [11, 12],  // 2
      [13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24],  // 12
      [25, 26, 27, 28, 29, 30],  // 6
  ];
  </code></pre>