title: Compiler gives error about undefined reference to a function
body: <p>Following is my code compiler says undefined reference to function . please elaborate what to do. Why does it give an error about <strong>undefined reference</strong> to the function <strong>isPalindrome()</strong> which is boolean?      </p>
  
  <pre><code>int main()
  {    
          cout &lt;&lt; "Please enter a string: ";
          cin &gt;&gt; input;
  
          cout&lt;&lt;"Vowel Count"&lt;&lt;vowelcount(input);
          while(1)
          {
                  if(isPalindrome())
                  {
                          palindrome_count++;
                  }
          }
          cout&lt;&lt;"palindrome_count"&lt;&lt;palindrome_count;
  }
  bool isPalindrome(string input)
  {
          do{
  
                  if (input == string(input.rbegin(), input.rend())) {
                          cout &lt;&lt; input &lt;&lt; " is a palindrome\n";
                  }
          }
          while(1);
  }
  </code></pre>