Ross Harvey wrote in post #990066:
> The s[n, 0] defines a place just before or after a character, and
> often before one and after another.
>
> So:
>
>   t = 'hi'
>   t[0,0] = '('
>   t[3,0] = ')'
>   t
> => "(hi)"

I'm new to Ruby and found this issue in one of the Ruby Koans[1] tests
(test_slicing_arrays).

As an outsider, using two different notions of an index (the element and
the space between elements) is very unexpected, especially for
syntax that is so closely tied (a[0] vs. a[0,0]).  Further, the 
documentation makes no effort to differentiate between the two notions 
(other than using 'index' and 'start').

If the only justification for this behavior is the example given above,
would it not be clearer to encourage str.insert and str.concat
(similarly, ary.insert and ary.concat)?

[1]: http://rubykoans.com/

-- 
Posted via http://www.ruby-forum.com/.