}
}while(miles > 0) ;
return(0);
}
when i input 1.609 i get an infitine loop that continues until i manually close the program
-- Posted by Eric 2009 at 6:54 pm on July 12, 2008
NEVERMIND!!!!
-- Posted by in loveeex3 at 6:55 pm on July 12, 2008
heehee nerd
-- Posted by HideOrSeek at 6:59 pm on July 12, 2008
"if (miles == 1.609){
cout<<"1 mile." < }
else{
cout <<"\nDistance is " << convert(miles) << " km." < }
}while(miles > 0) ;
return(0);
} " What if you get rid of the If, and instead converting in Else, just Convert whatever the user inputs?
Besides, why are you using a loop?
I think you just need to do the procedure once, you could use a loop when asking the user if he'd like to convert a different measure...
Hmn?