1std::vector<int> vec1;
2vec1.reserve(30); // Allocate space for 30 items, but vec1 is still empty.34std::vector<int> vec2;
5vec2.resize(30); // Allocate space for 30 items, and vec2 now contains 30 items.
you will get a confirmation link on this - you will have to click that for successful submission of your answer. we require this to keep the website free of spam, bots and unhelpful content
please ensure to add code which is syntactically corrent and executes properly
you will get a confirmation link on this - you will have to click that for successful submission of your question. we require this to keep the website free of spam, bots and unhelpful content