subject

Summary During each summer, John and Jessica grow vegetables in their backyard and buy seeds and fertilizer from a local nursery. The nursery carries different types of vegetable fertilizers in various bag sizes. When buying a particular fertilizer, they want to know the price of the fertilizer per pound and the cost of fertilizing per square foot. Instructions The following program prompts the user to enter the size of the fertilizer bag, in pounds, the cost of the bag, and the area, in square feet, that can be covered by the bag. The program should output the desired result. However, the program contains logic errors. Find and correct the logic errors so that the program works properly. //Logic errors. #include #include using namespace std; int main() { double cost; double area; double bagSize; cout > bagSize; cout > cost; cout > area; cout << endl; cout << "The cost of the fertilizer per pound is: $" << bagSize / cost << endl; cout << "The cost of fertilizing per square foot is: $" << area / cost << endl; return 0; } Format your output with setprecision(2) to ensure the proper number of decimals for testing!

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 13:30
In your ice breakers game, what happens when the snowball collides with one of the snowboards? a. the player's score will increase. b. the snowball will leave the play area. c. the snowball will be destroyed. d. the snowball will bounce.
Answers: 1
question
Computers and Technology, 22.06.2019 15:30
Which of the following examples has four beats in each measure?
Answers: 2
question
Computers and Technology, 22.06.2019 21:00
Kirk found a local community college with a two-year program and he is comparing the cost with that of an out-of-state two-year school. what is the expected total cost for one year at the local community college if kirk lives at home? what is the expected total cost for one year at the out-of-state school if kirk lives on campus?
Answers: 2
question
Computers and Technology, 23.06.2019 05:30
Sally is editing her science report about living things. she needs to copy a paragraph from her original report. order the steps sally needs to do to copy the text to her new document.
Answers: 1
You know the right answer?
Summary During each summer, John and Jessica grow vegetables in their backyard and buy seeds and fer...
Questions
question
Mathematics, 08.12.2020 02:20
question
Mathematics, 08.12.2020 02:20
Questions on the website: 13722361