changed method of array declaring