Skip to main content
Copy edited (e.g. ref. <http://en.wikipedia.org/wiki/C%2B%2B>). In English, the subjective form of the singular first-person pronoun, "I", is capitalized, along with all its contractions such as I'll and I'm.
Source Link
Peter Mortensen
  • 31.4k
  • 22
  • 110
  • 134

remove Remove ith item from c++a C++ std::vector

How do iI remove the ith item from a std::vectorstd::vector?

I know iI want to delete the ith element.

  I have int i; and std::vector<process> pList; where processprocess is a struct.

  I want to do something equiliventequivalent to the following:

pList.remove(i);

Thanks!

pList.remove(i); 

remove ith item from c++ std::vector

How do i remove the ith item from a std::vector

I know i want to delete the ith element.

  I have int i; and std::vector<process> pList; where process is a struct.

  I want to do something equilivent to the following:

pList.remove(i);

Thanks!

Remove ith item from a C++ std::vector

How do I remove the ith item from a std::vector?

I know I want to delete the ith element. I have int i; and std::vector<process> pList; where process is a struct. I want to do something equivalent to the following:

pList.remove(i); 
Post Closed as "Duplicate" by Cody Gray c++
Source Link
kralco626
  • 8.7k
  • 41
  • 116
  • 171

remove ith item from c++ std::vector

How do i remove the ith item from a std::vector

I know i want to delete the ith element.

I have int i; and std::vector<process> pList; where process is a struct.

I want to do something equilivent to the following:

pList.remove(i);

Thanks!