Method: Array#concat
- Defined in:
- lib/source/ruby.rb
#concat(ary) ⇒ Object
call-seq:
ary.concat(other) -> ary
Appends the elements in other to ary and returns ary.
[1,2].concat([3,4]).concat([5,6]) #=> [1, 2, 3, 4, 5, 6]
2058 2059 2060 2061 |
# File 'lib/source/ruby.rb', line 2058 def concat(ary) `for(var i=0,l=ary.length;i<l;++i){this.push(ary[i]);}` return self end |