title: c++: vector does not name a type
body: <p>very easy but frustrating question from me. </p>
  
  <pre><code>#include &lt;vector&gt;
  #include &lt;iostream&gt;
  
  using namespace std;
  
  vector &lt;int&gt; queue;
  
  queue.push_back(2);
  
  int main(){
      cout &lt;&lt; queue[0] &lt;&lt;endl;
  }
  </code></pre>
  
  <p>compiled with g++ -std=c++11 Cpp_test.cpp, return error </p>
  
  <pre><code>Cpp_test.cpp:51:1: error: ‘queue’ does not name a type
   queue.push_back(2);
  </code></pre>
  
  <p>Can anyone help? Thanks a lot!</p>