Hi everybody I need some professional help from experienced people. I am writing a program in C++ about a game. I have to specify a class Questions with attributes question, answers and difficulty. In the program i should have methods add, edit, select, search, print and remove. The problem that i have is that i have to work dynamically with these questions and when i choose from the menu save, just then to save everything into the file. So far i have ideas for everything except what kind of container to use?? I thought that i can use "map" but the key ( this should be the number of question) is const and if i delete a question the keys after that will remain the same. I need when i delete a question this integer ( question number) to decrease with 1. Can you give me an advise what kind of container to use and if i need to put question number as an attribute into the class.
Thank you in advance for the help
spawn2004 0 Newbie Poster
rubberman 1,355 Nearly a Posting Virtuoso Featured Poster
ravenous 266 Posting Pro in Training
spawn2004 0 Newbie Poster
Lucaci Andrew 140 Za s|n
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.