Question: In C++ please Integer variables numLemons and myMoney are read from input A lemon costs 2 dollars. - If numLemons is less than 4 ,

In C++ please
In C++ please Integer variables numLemons and myMoney are read from input

Integer variables numLemons and myMoney are read from input A lemon costs 2 dollars. - If numLemons is less than 4 , output "numLemons requires at least 4 to purchase." - If numlemons is greater than or equal to 4 , then multiply numLemons by 2. - If the product of numLemons and 2 is less than or equal to myMoney, output "Lemons successfully purchased". - Otherwise, output Not all lemons purchased. - If myMoney is greater than or equal to 2, output 'At least one item was purchased." - If numlemons is greater than 23, output "Now out of stock: . Otherwise, output "Item still in stock". End with a newline. Ex If the input is 1742 , then the output is Lemons successfully purchased. At least one item was purchased. Item still in stock

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!