subject

// the two senior class homerooms at littleville high school// are having a fundraising drive for the prom. each time a student// solicits a contribution, a record is created with the// student's name and the value. two files have been created for// homeroom a and homeroom b. each file is sorted in contribution// value order from highest to lowest. this program merges the two files. start declarations string roomaname num roomavalue string roombname num roombvalue string bothfilesdone = "n" num high_value = inputfile roomafile inputfile roombfile inputfile mergedfile getready() while bothfilesdone = "n" detailloop() endwhile alldone()stopgetready() open roomafile "roomafile. dat" open roombfile "roombfile. dat" open mergedfile "mergedfile. dat" reada() readb() checkboth()returnreada() input roomaname, roomavalue from roomafile if eof then roomavalue = high_value endifreturnreadb() input roombname, roombvalue from roombfile if eof then roombvalue = high_value endifreturncheckboth() if roomavalue = high_value and roombvalue = high_value then bothfilesdone = "y" endifreturndetailloop() if roomavalue > roombvalue then output roombname, roombvalue to mergedfile reada() else output roomaname, roomavalue to mergedfile readb() endifreturnalldone() close roomafile close roombfile close mergefilereturn

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 13:00
Donnie does not have powerpoint. which method would be best for elana to save and share her presentation as is? a pdf a doc an rtf a ppt
Answers: 3
question
Computers and Technology, 23.06.2019 20:30
What are some settings you can control when formatting columns?
Answers: 1
question
Computers and Technology, 24.06.2019 07:30
Consider the folloeing website url: what does the "http: //" represent? a. protocal identifier. b. ftp. c. domain name d. resource name
Answers: 2
question
Computers and Technology, 25.06.2019 01:00
What phrase indicates someone has knowledge and understanding of computer,internet,mobile devices and related technologies?
Answers: 1
You know the right answer?
// the two senior class homerooms at littleville high school// are having a fundraising drive for th...
Questions
question
Mathematics, 30.10.2020 20:50
question
Mathematics, 30.10.2020 20:50
question
Mathematics, 30.10.2020 20:50
Questions on the website: 13722362