Hi, All! I am learning C++ and new to this forum. I hope we will be all be helpful to each other.
For my questions:
When I run this program which converts USD to euros/yen depending on the user's choice, it runs properly when I use the inputs like 1y, 1 (return) y, and 1 (return) e, but when I use 1e, the program returns the else statement. Why is that?
Here is my program in int main;
const double ytd=1/360.0, etd=1/1.287;
cout<<"Please enter the amount of USD then the letter 'e' to be converted to euro or"<<
" letter 'y' to be converted to yen.\n";
cout<<"You have "<<d*ytd<<" yen\n";
cout<<"You have "<<d*etd<<" euros\n";
cout<<"I do not know this currency.\n";
/* ytd=yen to dollars
etd=euro to dollars
I am trying to make a C++ program that would arrange three words in alphabetical order. Note that I did one for arranging three integers from least to greatest. Any help?
Plus, why when I add/multiply/divide/subtract double numbers and store them into a double variable, it will store them as int?
Is this true? http://www.gidnetwork.com/b-61.html