Learning C, need some assistance with “Greedy” CS50 solution
I am very new to C. I come from a python background. I would like to know where I went wrong with my code. I am doing the cs50 greedy problem. What is wrong with my code? It works with some numbers but others don't work. I am trying to get an input from the user asking how much change to give back, then calculate the minimum number of coins I can give back using only $.25, $.10, $.05, $.01 #include <cs50.h> #include <stdio.h> int main(void) { float n; do { n = get_float("How much change is owed?\n"); } while(n == EOF); int minimumamountofcoins = 0; if (n/.25 >=1){ do { n -= .25;