程序代写代做代考 Sample Solutions for Quiz 3, Question 6, 2PMMS Seeks Version 1: 72,000 pages

Sample Solutions for Quiz 3, Question 6, 2PMMS Seeks Version 1: 72,000 pages
a) [1 mark] Read into input buffers = 72 LS and 0 SS b) [3 marks] Write from output buffers
a. 2 marks for computing 1 LS and 5 SS per output buffer
b. 1 mark for multiplying this by the correct number of times that the output
buffer was written, that is, 72/6 = 12 output buffer fills
c. Thus,totalwritecomponent=12*(1LS+5SS)=12LS+60SS
i. Note: If they didn¡¯t get 1 LS + 5 SS, but multiplied their numbers of LS and SS by 12, that¡¯s OK for 1 mark out of 3.
Version 2: 120,000 pages
a) [1 mark] Read into input buffers = 120 LS and 0 SS b) [3 marks] Write from output buffers
a. 2 marks for computing 1 LS and 1 SS per output buffer
b. 1 mark for multiplying this by the correct number of times that the output
buffer was written, that is, 120/2 = 60 output buffer fills
c. Thus,totalwritecomponent=60*(1LS+1SS)=60LS+60SS
i. Note: If they didn¡¯t get 1 LS + 1 SS, but multiplied their numbers of LS and SS by 60, that¡¯s OK for 1 mark out of 3.
Version 3: 96,000 pages
a) [1 mark] Read into input buffers = 96 LS and 0 SS b) [3 marks] Write from output buffers
a. 2 marks for computing 1 LS and 3 SS per output buffer
b. 1 mark for multiplying this by the correct number of times that the output
buffer was written, that is, 96/4 = 24 output buffer fills
c. Thus,totalwritecomponent=24*(1LS+3SS)=24LS+72SS
i. Note: If they didn¡¯t get 1 LS + 3 SS, but multiplied their numbers of LS and SS by 24, that¡¯s OK for 1 mark out of 3.
Version 4: 60,000 pages
a) [2 marks] Read into input buffers
a. 1 mark for computing 1 LS + 1 SS per fill
b. 1 mark for multiplying this by the correct number of times that each input
buffer was written into, that is, 60/2 = 30 input buffer fills
1

c. Thus,totalreadcomponent=30*(1LS+1SS)=30LS+30SS
i. Note: If they didn¡¯t get 1 LS + 1 SS, but multiplied their numbers of LS and SS by 30, that¡¯s OK for 1 mark out of 2.
b) [2 marks] Write from output buffers
a. 1 mark for computing 1 LS and 1 SS per output buffer
b. 1 mark for multiplying this by the correct number of times that the output
buffer was written, that is, 60/2 = 30 output buffer fills
c. Thus,totalwritecomponent=30*(1LS+1SS)=30LS+30SS
i. Note: If they didn¡¯t get 1 LS + 1 SS, but multiplied their numbers of LS and SS by 30, that¡¯s OK for 1 mark out of 2.
2