Firstly, don't use Magic Numbers. You used "arr_size" in your first loop, use it in your second as well. Otherwise you run the risk of changing the size in one place, and your code fails because you didn't change t in the other.
for (counter = arr_size - 1; counter >= 0; --counter)
printf(" %g",numbers[counter]);
To reverse the order of printing, you could do this two ways:
for (counter = arr_size; counter > 0; --counter)
printf(" %g",numbers[arr_size - counter]);
Or
for (counter = 0; counter < arr_size; ++counter)
printf(" %g",numbers[counter]);
BTW: It is a convention to use postfix notation in
for
loops - not mandatory, but normal:
Instead of
for (counter = arr_size - 1; counter >= 0; --counter)
printf(" %g",numbers[counter]);
Use
for (counter = arr_size - 1; counter >= 0; counter--)
printf(" %g",numbers[counter]);
[edit]Typo: Forgot to remove old condition from for loop when adding new condition - it's early! - OriginalGriff[/edit]