I am doing some C++ exercises and got stuck with one.
I have written 1 version of the program to use vectors to store values, and the other to use lists to store values.
This is the next exercise: By using a typedef, we can write one version of the program that implements either a vector-based solution or a list-based one.
Write and test this version of the program.
v1. If I understand correctly I am supposed to write a program to declare a type that works the same with lists and vectors.
v2. The other easy version would be that I am supposed to declare shorter declaration names with typedef for example for lists of my list version of the program. And same to my vector based program.
Can anyone help me to understand it right?
Here is the list version of the program(vector based is the same only vectors instead of lists).