Answer to Question #262999 in C++ for Rille

Question #262999

Make a program that will input Dollar currency, convert it into peso. Peso= dollar



currency*50.00 pesos, Display the peso equivalent. Your program will be terminated if the



inputted Dollar currency = 0.

1
Expert's answer
2021-11-09T23:39:00-0500

Source code



#include <iostream>


using namespace std;


int main()
{
    while(true){
        double dollars;
    	cout<<"\nEnter dollars: ";
    	cin>>dollars;
    	
    	if (dollars==0){
    	    break;
    	}
    	double peso=dollars*50.00;
    	
    	cout<<"The equivalent of $"<<dollars<<" is "<<peso<<" pesos";
    }
    
	


    return 0;
}



Output






Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS