found the right number of indices