I think you want to be assigning to "potions[i]", rather than "potions[0]".