Question: Please help with C++ program Jump to level 1 Integers numCakes and numDollars are read from input. A cake costs 17 dollars. - If numCakes

Please help with C++ program
Jump to level 1 Integers numCakes and numDollars are read from input. A cake costs 17 dollars. - If numCakes is less than 4, output "numCakes is less than the required amount to purchase." - If numCakes is greater than or equal to 4 , then declare and initialize int variable totalCost with the product of numCakes and 17. - If totalCost is less than or equal to numDollars, output "Approved transaction." - Otherwise, output "Not all cakes purchased." End with a newline. Ex: If the input is 11 188, then the output is: Approved transaction. 1 \#include 2 using namespace std; 3 4 int main() \{ 5 int numCakes; 6 int numDollars
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
