What is the difference between following two statements?
const std::vector<int> v1;
and
std::vector<int> const v2;
Is both statements equivalent?
What is the difference between following two statements?
const std::vector<int> v1;
and
std::vector<int> const v2;
Is both statements equivalent?
Yes. They are both equal. The best way to understand const is to read it as applying to the token left to it (Unless it's the leftmost token - in that case it applies to the immediate token to the right).
See https://isocpp.org/wiki/faq/const-correctness#overview-const