In a particular program, it is found that 1% of the code accounts for 50% of the execution time. To code the program in FORTRAN, it takes 100 man-days. Coding in assembly language is 10 times harder than coding in FORTRAN, but runs 5 times faster. Converting (rewriting) an existing FORTRAN program to an assembly language program is 4 times harder than coding in FORTRAN.
The entire program is written in FORTRAN. The percentage decrease in the execution time, resulting from rewriting the 1% of code (that accounts for 50% of execution time) into assembly language, is
Pick an option to check yourself, or open the answer below.
Show answer & explanation
Correct answer: C. 40
Explanation
Normalize the original total execution time to 100 units. The 1% of code that is rewritten in assembly accounts for 50 of these units, and the remaining 99% of the code (left unchanged) accounts for the other 50 units. Since assembly code for that hot 1% runs 5 times faster, its execution time falls from 50 to 50/5 = 10 units, giving a new total of 50 + 10 = 60 units. The decrease is 100 - 60 = 40 units out of the original 100, a 40% decrease.More Software Engineering questions
- If 99% of the program is written in FORTRAN and the remaining 1% directly in assembly language, the percentage increase in the execution ti…
- If a project team needs 13 days to completely write the program in FORTRAN and rewriting (converting) the 1% code to assembly language, the…
- How many days will it take for 2 programmers to write the entire code in FORTRAN and then rewrite the 1% code to assembly language?
- If 99% of the program is written in FORTRAN and the remaining 1% in assembly, the percentage increase in the programming time compared to w…
- Match List I (Software Quality Characteristic) with List II (Description)List I List II A. Reliability I. Ability to transfer the software…
- The process followed in order to find difficult, unknown and hidden information about a software system is called