4 Ağustos 2007 Cumartesi

Remove elements in an array by indexes

# Remove elements in an array by indexes

def deleteFromAry( ary, idxs )
cnt = 0
idxs.each { |i|
ary.delete_at( i - cnt )
cnt = cnt + 1
}
end


0 Comments: