First off, dont use more than 1 endl ever. Use "\n" if you want to add a verticle space, but dont use several endl's because it becomes useless to flush the buffer so many times.
Ok, first:
Code:
float money = 0.0 // amount of money i have
money = (quarters * .25) + (dimes * .10) + (nickles * .5) + (pennies * .1);
This is bad. You are attempting to turn an int into a float. (Why are you using a float? Use a double, its more accurate.) You have to cast an int into a float before you can use it in equasions with floating numbers! The simplest way to fix this is to convert all your ints to floats (or doubles). Also, the way you use cin >> to get number input is very bad. If the user types in a letter, cin wont understand it.
Code:
#include <iostream>
using namespace std;
int main() {
double quarters, dimes, nickles, pennies;
cout << "Enter the number of quarters:";
cin >> quarters;
cout << "\nEnter the number of dimes :";
cin >> dimes ;
cout << "\nEnter the number of nickles :";
cin >> nickles ;
cout << "\nEnter the number of pennies :";
cin >> pennies ;
cout << quarters << " " << dimes << " " << nickles << " " << pennies << " " << endl;
float money = 0.0; // amount of money i have
money = (quarters * .25) + (dimes * .10) + (nickles * .05) + (pennies * .01);
cout << "you have this amount : $" << money << endl;
return 0;
}
That should work, I know you cant have a fraction of a coin, but you have to cast int's to float's before you can multiply them by decimals, I would tell you how, but I dont remember -,-.