When I create a new JavaScript array, and use an integer as a key, each element of that array up to the integer is created as undefined.
For example:
v
Try using an Object, not an Array:
var test = new Object(); test[2300] = 'Some string';