Confused about how rounding floats work : **I'm trying to round the value that I gain through 'GetFloat()' (say .478 to .48) and then use it in the if statements but i'm somewhat confused regarding rounding floats and such. Will i also need to cast it to an int?
I'd greatly appreciate any help you can give with my code.**


----------

        #include <stdio.h>
        #include <math.h>
    
        int main(void)
        {
        //declared variables
        float change;
        int num = 0;
        float change_r;
        
        // prompts for amount owed
        {
            printf("Please provide the amount owed: ");
            change = GetFloat() * 100;
            while (change > 0)
            float change_r = roundf(change);
        }
        {
            // if statements for calculating number of coins required
            if (change >= 25)
            {
                change = change - 25;
                num ++;
            }
            if (change >= 10 && change < 25)
            {
                change = change - 10;
                num ++;
            }
            if (change >= 5 && change < 10)
            {
                change = change - 5;
                num ++;
            }
            if (change >= 1 && change < 5)
            {
                change = change - 1;
                num ++;
            }
        }
        printf("%d\n", num);
    }

