A hierarchy chart tells you.
a. what tasks are to be performed within each program module
b. when a module executes
c. which routines call which other routines
d. all of the above
The Correct Answer and Explanation is:
The correct answer is:
c. which routines call which other routines
Explanation:
A hierarchy chart is a visual representation used in software engineering and programming to depict the organization and structure of a system’s modules or routines. It is sometimes called a structure chart or call graph, and it primarily shows the relationships and calling hierarchy among modules or routines in a program.
What does a hierarchy chart show?
- Which routines call which other routines: The main purpose of a hierarchy chart is to illustrate the flow of control between different modules. It shows a top-down view starting with the main module at the top and branches that represent subordinate modules or subroutines called by the main module. Each connection or arrow indicates that one module calls or invokes another. This helps programmers understand the program’s modular design, how the code is structured, and the calling relationships.
What it does NOT typically show:
- What tasks are to be performed within each program module (Option a): This detail is not shown by hierarchy charts. Instead, this information is usually found in detailed module specifications, pseudocode, or flowcharts. The hierarchy chart only shows which modules are connected, not the internal workings or specific tasks of each module.
- When a module executes (Option b): Timing or the sequence of execution is not depicted in a hierarchy chart. Execution order can be inferred somewhat from the hierarchy, but exact timing or conditions for execution require other diagrams such as flowcharts, sequence diagrams, or state charts.
Why is hierarchy chart useful?
Hierarchy charts help developers and analysts understand the overall program structure quickly. They clarify the modular relationships and dependencies, making it easier to maintain or modify the system. When debugging or enhancing software, knowing which module calls which is crucial, as changes in a called module can affect its callers.
