Cognizant Interview Question

vector internal memory allocation during element addition and removal