mutate array in-place to subtract a scalar value