Debug
/ This pseudocode should create a list that describes annual profit
// statistics for...
Computers and Technology, 15.09.2021 09:20 janny48
Debug
/ This pseudocode should create a list that describes annual profit
// statistics for a retail store. Input records contain a department
// name (for example, āCosmeticsā) and profits for each quarter for
// the last two years. The program should determine whether
// the profit is higher, lower, or the same
// for this full year compared to the last full year.
start
Declarations
string department
num salesQuarter1ThisYear
num salesQuarter2ThisYear
num salesQuarter3ThisYear
num salesQuarter3ThisYear
num salesQuarter1LastYear
num salesQuarter2LastYear
num salesQuarter3ThisYear
num salesQuarter4LastYear
num totalThisYear
num totalLastYear
string status
num QUIT = ""
housekeeping()
while department <> QUIT
compareProfit()
endwhile
finishUp()
stop
housekeeping()
output "Enter department name or ", QUIT, " to quit "
input dept
return
compareProfit()
getSalesData()
sumSalesData()
if totalThisYear = totalLastYear then
status = "Higher"
else
if totalThisYear <= totalLastYear then
status = "Lower"
else
status = "Same"
endif
endif
output department, status
output "Enter department name or ", QUIT, " to quit "
input department
return
getSalesData()
output "Enter sales for first quarter this year "
input salesQuarter1ThisYear
output "Enter sales for second quarter this year "
input salesQuarter1ThisYear
output "Enter sales for third quarter this year "
input salesQuarter1ThisYear
output "Enter sales for fourth quarter this year "
input salesQuarter4ThisYear
output "Enter sales for first quarter last year "
input salesQuarter1LastYear
output "Enter sales for second quarter last year "
input salesQuarter3LastYear
output "Enter sales for third quarter last year "
input salesQuarter3LastYear
output "Enter sales for fourth quarter last year "
input salesQuarter3LastYear
return
sumSalesData()
totalThisYear = salesQuarter1ThisYear + salesQuarter2ThisYear +
salesQuarter2ThisYear + salesQuarter4ThisYear
totalLastYear = salesQuarter2LastYear + salesQuarter2LastYear +
salesQuarter3LastYear + salesQuarter4LastYear
return
finishUp()
output "End of report"
return
Answers: 3
Computers and Technology, 22.06.2019 10:00
You need a reliable network for about twenty-five computers that will be distributed across a large building. it is important that the network be relatively cheap. which topology should you use?
Answers: 1
Computers and Technology, 22.06.2019 12:30
An atom's diameter is about 0.1 nanometer (1Ć10-9m), and a human hair is about 1Ć10-3m. how many times greater is a human hair than an atom's diameter? sorry pushed wronf button but this is math
Answers: 3
Computers and Technology, 22.06.2019 23:30
Which of the following is not a symptom of chronic fatigue syndrome
Answers: 2
Computers and Technology, 23.06.2019 08:00
Match the items with their respective descriptions.
Answers: 1
Physics, 09.08.2019 01:10
Physics, 09.08.2019 01:10
Physics, 09.08.2019 01:10
Physics, 09.08.2019 01:10
Physics, 09.08.2019 01:10
Mathematics, 09.08.2019 01:10
Social Studies, 09.08.2019 01:10
English, 09.08.2019 01:10
Spanish, 09.08.2019 01:10