Add foreach with slice of arrays.