Rounding still won't work on the CS50 pennies problem from week1 my code is below
#include <cs50.h>
#include <math.h>
#include <stdio.h>
int main(void)
{
float amount = get_float("Dollar Amount: ");
int pennies = amount * 100;
printf("Pennies: %i\n", pennies);
}
But this still returns if I use Davids's example of 4.20 it still rounds to 4.19 is there something I'm missing?
Thanks