#MATL, 11 bytes YPiEY$VGH+) This solution utilizes 1-based indexing [**Try it Online**](http://matl.tryitonline.net/#code=WVBpRVkkVkdIKyk&input=MTAwMDE)