The instructions of a program can be categorized into three
Solution
From the question, there are 3 types of instructions (A-10, B-15 and C-75). Total time taken by the program (which is equal to sum of all the instructions time) is 100 sec.
Since, each instruction set takes equal amount of time to execute (as per question), each of the instructions of type A, B and C take 1 second for execution.
a) If type C insturctions are improved by a factor of 3,
Time taken by the C instructions come down by 3. It means the time taken would reduce from 75 to (75/3) = 25.
Total time of the program = 10 (A)+ 15 (B) + 25 (C-updated) = 50
b) If type A and type B are factored by 5,
Time taken by the A and B instructions will come down by 5. It means the time taken would reduce from 10 and 15 to (10/5) and (15/5) for A and B respectively.
Time taken by the program = 2 (A-updated) + 3 (B-updated) + 75 = 80
