refactored to abstract index manipulation to a question manager class