check the length of the accessed vector (`v[]`) too