title: expected initializer before â token
body: <p>When I try to build a forloop for vector like this:</p>
  
  <pre><code>  vector&lt;int&gt; v;
  
    int  a;
      while (cin&gt;&gt;a){
        if(i&lt;=0 || i&gt;=10)
          cout &lt;&lt; "Please enter int between 0 and 10:" &lt;&lt; endl;
        else
          v.push_back(a);
      }
  
    int min;
    int sum;
    for (int &amp;i: v){
      if(v.empty())
        min = i;
      else(i&lt;min){
       min = i;
      sum += i;
      }
    }
  </code></pre>
  
  <p>It shows :expected initializer before â token</p>
  
  <p>Where did i get wrong? Thanks so much!</p>
  
  <p>.bashrc:</p>
  
  <p>Here is my .bashrc:</p>
  
  <pre><code>  # .bashrc
  
      # User specific aliases and functions
      export PATH=/usr/remote/gcc-4.8/bin:$PATH
      export LD_LIBRARY_PATH=/usr/remote/gcc-4.8/lib:$LD_LIBRARY_PATH
      alias g++='g++ -std=c++11'
  
  
      # Source global definitions
      if [ -f /etc/bashrc ]; then
          . /etc/bashrc
      fio9
  </code></pre>