Code:
struct data {
  string name;
  string title;
  string author;
};

vector <data> books;
Say that you have an x ammount of names, decided by the user, that needs to be put inside the vector. How do you do that in the example provided using a for loop (where i < x)?