Skip to content

Instantly share code, notes, and snippets.

/.rb Secret

Created November 30, 2014 00:31
class Array
def each_with_index_starting_at(start_index)
self.each_with_index do |item, index|
yield item, index + start_index
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment