using array to put messages