9618 · 11.3
Structured Programming — FAQ
Frequently asked questions for 9618 Structured Programming. Direct answers first, then deeper explanation — then practise with marking.
What is the difference between top-down design and stepwise refinement?
In the context of the A-Level syllabus, they are treated as the same concept. Both refer to the process of breaking a large, complex problem into a hierarchy of smaller, more manageable sub-problems.
Why are `GOTO` statements bad practice in structured programming?
GOTO statements create unconditional jumps in the program's execution path. This makes the code's logic incredibly difficult to follow, debug, and maintain, a problem often called 'spaghetti code'. Structured programming replaces this with clear, predictable control structures like loops and conditionals.
Can I nest control structures within each other?
Yes, absolutely. Nesting is a key part of building complex logic from simple blocks. For example, you can have a FOR loop (iteration) that contains an IF statement (selection) to process items in a list, or even another loop inside the first one.
Are procedures and functions part of structured programming?
Yes. Procedures and functions are the primary way to implement the modules identified during top-down design. They encapsulate a specific piece of logic, making the program modular, reusable, and easier to understand.