title: 'cout' was not declared in this scope
body: <p>I have a C++ program:</p>
  
  <p><strong>test.cpp</strong></p>
  
  <pre><code>#include&lt;iostream&gt;
  
  int main()
  {
      char t = 'f';
      char *t1;
      char **t2;
      cout&lt;&lt;t;    //this causes an error, cout was not declared in this scope
      return 0;
  }
  </code></pre>
  
  <p>I get the <strong>error</strong>:</p>
  
  <blockquote>
    <p>'cout' was not declared in this scope</p>
  </blockquote>
  
  <p>Why?</p>