Hey guys, long time reader -- with maybe one post I think. I'm pretty new to C++ but can hold my own.... but I was looking for some help.
What is the best way to go about allowing the user to input as many inputs as they want, then when they stop the program will print all inputs in reverse.
The reverse part is easy, and declaring and all. What I can't comprehend is the best way to declare an Unknown number of inputs so that the program can then print those inputs back in reverse.
I don't want any code as much as I want an explanation as to what functions and procedures would work best for this situation.
I'm no copy and paster and I love learning C++ -- not plagiarizing. :)
- Ask user how many arguments they would like to input.
- If inputs less than 1, tell user that their request cannot be processed.
- If greater than or equal to 1, continue.
From there... not sure if I need to just declare a dozen input strings/numbers and then ask the user after each input if they are done...
There must be a much more efficient way to do this using a while loop.
Thanks a lot guys/gals.