Pre-allocating the array