Change making is a difficult problem. It's usually easy to find a trivial solution (all units), and a better algorithm (take the highest note and subtract until you can do no more, then repeat with the next highest note) is also fairly easy. But you can do better.

What I suggest is that you start with the interface. You need to pass the amount of money, and the notes availbale in, and you need a list of notes out.

So I suggest

Code:
void makchange(long amount, const long *denominations, int Ndenominations, long *notesout)
You call it like this

Code:
long denominations[6] {50, 20, 10, 5, 2, 1}; // notes avialable
long amount = 210;
long notes[6]; // where we store the notes

makechange(amount, denominations, 6, notes);
for (i = 0; i < 6; i++)
{
    if (notes[i] > 0)
       printf("%ld note : %ld\n" denominations[i], notes[i]);
}