Is vectorvec(5) and vector[5] both means that the size of the vector is 5 or not. If not please explain the difference.
Confusion in syntax
hi @nikhil015
-
vector<int> vec(5)will make a vector of size 5 -
vector<int>vec[5] will make an array of vectors, the size of array will be 5, the size of each vector of that array will be 0.
