diff --git a/C/#include #include int main() { float avgProfit; int priceOfPumpkin = 10; int sales = 59; int daysWorked = 7; avgProfit = (float)priceOfPumpkin * (float)sales/16_cProgramming.c b/C/#include #include int main() { float avgProfit; int priceOfPumpkin = 10; int sales = 59; int daysWorked = 7; avgProfit = (float)priceOfPumpkin * (float)sales/16_cProgramming.c new file mode 100644 index 0000000..7061c22 --- /dev/null +++ b/C/#include #include int main() { float avgProfit; int priceOfPumpkin = 10; int sales = 59; int daysWorked = 7; avgProfit = (float)priceOfPumpkin * (float)sales/16_cProgramming.c @@ -0,0 +1,16 @@ +#include +#include + +int main() +{ + float avgProfit; + int priceOfPumpkin = 10; + int sales = 59; + int daysWorked = 7; + + avgProfit = (float)priceOfPumpkin * (float)sales / (float)daysWorked; + printf ("Average Daily Profit: $%.2f", avgProfit); + + return 0; +} +