Do While loop is not working?
<p>in my program. my do-while loop is not working and I have no idea why. All i wanted the do-while loop to do is to alleviate the need for the user to re-run the program when he wants to enter another number.</p>

<pre><code>#include&lt;iostream&gt;
#include&lt;string&gt;
double tester;
using namespace std;
double squarerootfinder(double number, double divisor){
    tester = (number / (divisor * divisor ));
    if(divisor == 1){
            return 1;
     }
     else{
             if(tester != (int)tester )

            divisor = squarerootfinder(number, divisor - 1);
            }
    return divisor;
    }
int main(){
    string runagain;
    double number, divisor, squareroot, insidepart;

do{    
     cout &lt;&lt; "Enter a whole number to find the square root of it \n";
     cin &gt;&gt; number;
     divisor = number;
     squareroot = squarerootfinder(number, divisor);
     insidepart = number / (squareroot * squareroot);
     if(insidepart != 1){
          cout &lt;&lt; squareroot &lt;&lt; (char)251 &lt;&lt; insidepart;
          cout &lt;&lt; endl;
     }
     else{
          cout &lt;&lt; squareroot &lt;&lt; endl;                  
     }
     string runagain;
     cout &lt;&lt; "written by Arpan Gupta! \n";
     cout &lt;&lt; "Enter run again to run the program again. \n";
     cin &gt;&gt; runagain;
     }while(runagain == "run again" || runagain == "RUN AGAIN");             
     return 0;
}
</code></pre>
