title: c++ compile error: ISO C++ forbids comparison between pointer and integer
body: <p>I am trying an example from Bjarne Stroustrup's C++ book, third edition. While implementing a rather simple function, I get the following compile time error:</p>
  
  <pre><code>error: ISO C++ forbids comparison between pointer and integer
  </code></pre>
  
  <p>What could be causing this? Here is the code. The error is in the <code>if</code> line:</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;string&gt;
  using namespace std;
  bool accept()
  {
      cout &lt;&lt; "Do you want to proceed (y or n)?\n";
      char answer;
      cin &gt;&gt; answer;
      if (answer == "y") return true;
      return false;
  }
  </code></pre>
  
  <p>Thanks!</p>