I define a very simple vector: std::vector v; Then when I want to add an element to this vector I cannot reach to member functions of this vector: v.push_back(1); This code gives error "unknown type name v". I use QT Creator
my code:
#include <iostream> #include <vector> std::vector<int> v; v //when I write this "unknown type name v" error comes out. int main() { }
1.4m articles
1.4m replys
5 comments
57.0k users