attempt to use array logic