The algorithm for solving the problem is shown below. However, you'll probably want to put it in its own method so you don't keep copying and pasting code that performs the same operation several times in a row.
Code:
double money = 1234.70; // arbitrary value chosen
int hundreds = money / 100; // determine the number of hundreds
money -= hundreds * 100; // subtract all the hundreds
// now do the same thing for each group (fifties, tens, fives, ...)
Does this solve your problem?