The goal of my assignment is to convert US dollars to Euros. All I need to do is prompt the user of an input and then use functions to get the output Im new to coding, and for the life of me can not find where I went wrong in declaring this function. any advice is appreciated.
#include <iostream>
using namespace std;
double getmoney();
double convert();
double display();
int main()
{
cout.setf(ios::fixed);
cout.setf(ios::showpoint);
cout.precision(2);
getmoney();
display();
return 0;
}
double getmoney()
{
double money;
cout << "Please enter the amount in US Dollars: ";
cin >> money;
return money;
}
double convert(double money)
{
double euros;
euros = money * 1.41;
return euros;
}
double display(double money)
{
cout.setf(ios::fixed);
cout.setf(ios::showpoint);
cout.precision(2);
double salad = convert(money);
cout << getmoney() << endl;
if (money >= 0)
cout << "Euros: " << salad;
else (money < 0);
cout << "Euros: " << "(" << salad << ")";
return 0;
}