check the size of vector