I am still learnning the basics of C++ and have been given the assignment of writing my own currency converter program. I have tried to figure as much out from the book as I can and also studied so examples I found online But know I am stuck. Can some one please take a look and see what I have done wrong.
//This program converts U.S. Dollars to Yen
#include <iostream>
using namespace std;
char choice;
void knownexchangerate()// chose if you know the current exchange rate
{
float solve1; // dollars * exchange rate = yen
float amount1; // amount in U.S. dollars
float exrate1; // exchange rate
cout <<"Enter the amount in U.S. Dollars you want that you want to convert to Yen." <<endl;
cin >>amount1;
cout <<"Enter the current exchange rate. " <<endl;
cin >>exrate1;
void unknownexchangerate()
{
float solve1; // dollars * exchange rate = yen
float amount1;// amount in U.S. dollars
cout <<"Enter the amount in U.S. Dollars you want that you want to convert to Yen." <<endl;
cin >>amount1;
solve1 = amount1*81.25; // amount of US dollars * 81.25 exchange rate as of 11-19-2012
cout << solve1 <<" Yen." <<endl;
}
int main()
{
cout <<"Do you Know the current exchange rate for U.S. Dollars to Yen? Enter 1 for yes 2 for no " <<endl;
cout <<"1)Yes 2)no " <<endl;
cin >>choice;
if (choice == '1')
{
knownexchangerate();
}
else if (choice == '2')
{
unknownexchangerate();
}
else cout <<"Not a valid choice. Please enter one of the following: 1 or 2 " <<endl;
return 0;
}
The program appears to work but I keep getting the message
Debugging information for Odom final.exe cannot befound or does not match. Binary was not built with debug information. other than that it appears to work I even tweaked it some.