Modify how add() obtains index positions