changes array to initialize with a capacity