Difficulty: Easy
Correct Answer: subroutine
Explanation:
Introduction / Context:
Code reuse and modularity are central to software engineering. In assembly and higher-level languages alike, programmers encapsulate a repeated operation in a callable unit so that it is written once and used many times, reducing duplication and improving maintainability.
Given Data / Assumptions:
Concept / Approach:
The standard term for such a reusable program unit is “subroutine.” In various languages, equivalent terms include function, procedure, method, or routine. In assembly, CALL transfers control to the subroutine; RET returns to the caller, often using the stack for return addresses and parameters.
Step-by-Step Solution:
Verification / Alternative check:
Programming texts and ABIs define subroutines with calling conventions (parameter passing, register saving, return values).
Why Other Options Are Wrong:
Common Pitfalls:
Confusing interrupts with normal calls; mixing “macro” (textual expansion) with subroutines (single copy executed via call).
Final Answer:
subroutine
Discussion & Comments