Check out example codes for "insert at position in vector c++". It will help you in understanding the concepts better.

Code Example 1

// where v is the vector to insert, i is
// the position, and value is the value

v.insert(v.begin() + i, v2[i])

Learn ReactJs, React Native from akashmittal.com