When I compile it, it shows" no matching function for call to ....."
can anyone help me? Thanks a lot!
#include <iostream>
#include <vector>
using namespace std;
void PrintVectors(vector<int> numsList) {
int i;
for (i = 0; i < numsList.size(); ++i) {
cout << numsList.at(i) << " ";
}
cout << endl;
}
int main() {
vector<int> numsList;
numsList.push_back(101);
numsList.push_back(200);
numsList.push_back(103);
/* Your solution goes here */
numsList.erase(numsList.at(1));
numsList.insert(numsList.at(0), 100);
numsList.insert(numsList.at(2), 102);
PrintVectors(numsList);
return 0;
}
I see. Thank you so much!