Data.List: add with_index()

hi.
I suggest adding with_index() function which is inspired by Ruby's
with_index method.

with_index({list} [, {offset}])

Returns {list} with index. {offset} means the base of index.
If you specify {offset}, index starts with {offset}.

    :echo List.with_index(['a', 'b', 'c'])
    [['a', 0], ['b', 1], ['c', 2]]

This function is useful when used with |:for|.
For example, when you have lines as a list of string and you want to
output a line with a line number to each line, you may write as below.

    for idx in range(1, len(lines))
        echo idx.': '.lines[idx]
    endfor

This procedure can be rewritten using with_index() as below.

    for [line, idx] in List.with_index(lines, 1)
        echo idx.': '.line
    endfor
Merge pull request #62 from rhysd/with_index

Data.List: add with_index()