I am trying to put a new item to vector, and shift remaining items. How can I do that ?
Ex
vector -------------------------------------------------------
| 1 | 2 | 3 | 4 | 5 | 9 | 10 | 15 | 21 | 34 | 56 | 99 |
-------------------------------------------------------
^
new item = 14, it should be added to ^
After insertion,
vector ------------------------------------------------------------
| 1 | 2 | 3 | 4 | 5 | 9 | 10 | 14 | 15 | 21 | 34 | 56 | 99 |
------------------------------------------------------------
^ ^
^-shifted to right by one-^
Check the vector::insert() function.