Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

i need help finding more errors on this debug and can you check if i did mine ri

ID: 3594938 • Letter: I

Question



i need help finding more errors on this debug and can you check if i did mine right too? thank you

This pseudocote should create list that describes annual profit // statistics for a retailI store 2 nane (for exaple. "cosnoties") and profits for each quarter for // , tnput records contain departnent // the last two years, / the prafit is higher, lower, or the sare The progras should deternine shether // for this full I year conpared to the last full year. Declarations string departeent nue salesQuarter1T nus salesquarter2Thisyear nun salesQuartep3ThisYear nus salesQuarter3Thisyear nun salesquarterzLastyear hisyear nin salesQuarter3 nun salesQuarter4Lastvear nun totalLastYear string status necessary housekeeping() - (S while departaent > QuIT ne copareProfit() endwhile finishüp() stop housekeeping) output "Enter departnent nane or ",QUIT, to quit " input dept corpareProfit() getsalesData() sunsalesData() if totalThisyear totallastyear then status- "higher" if totalThisYear

Explanation / Answer

Althought the pseudocode looks good.Only one thing it might give error.The variable declaration should be made global . Otherwise the code is good to go.