1: #include <iostream>
2: using namespace std;
3:
4: int main()
5: { cout << "How many pennies do you have? ";
6: int count;
7: cin >> count;
8:
double total = count * 0.01;
9: 

10: cout << "How many nickels do you have? ";
11: cin >> count;
12:
total = count * 0.05 + total;
13:
14: cout << "How many dimes do you have? ";
15: cin >> count;
16: total = count * 0.10 + total;
17:
18: cout << "How many quarters do you have? ";
19: cin >> count;
20:
total = count * 0.25 + total; 21: 22: cout << "Total value = " << total << "\n"; 23: return 0; 24: }