Is there any difference between Structured and Procedural Paradigm

paradigms

Procedural Paradigm according to Wikipedia:

Procedural programming is a programming paradigm, derived from structured programming, based on the concept of the procedure call. Procedures, also known as routines, subroutines, or functions, simply contain a series of computational steps to be carried out. Any given procedure might be called at any point during a program's execution, including by other procedures or itself.

Structured Paradigm According to Wikipedia:

Structured programming is a programming paradigm aimed at improving the clarity, quality, and development time of a computer program by making extensive use of the structured control flow constructs of selection (if/then/else) and repetition (while and for), block structures, and subroutines.


Both of those definition are similar. I can't find a difference between the two definitions.

Both of them have:

  1. procedures that can be called.
  2. control structure, to alter control flow

Is it enough to base their difference on: procedural can call other functions within a function including itself while structured can only call a function from the main function?

What exactly differentiates these two paradigms?

Best Answer

These two terms are addressing different though related concepts.

Both seek to improve lessor programming paradigms by increasing the separation of concerns between program constructs, compartmentalization of components, organization of code.

Let's also note that that in the Wikipedia article, the assertion that procedural programming derived from structured programming needs a citation.  And as @MartinMatt says, the term is usually used in opposition to OOP, which has additional constructs for organization & abstraction.


Structured means block structuring, such as if-then-else, while, for, etc..  Using these eliminates goto's and labels, and make programs more readable and less error prone.  (Naming labels is a chore that is error prone.)  Blocks also nicely nest.

Procedural programming means using functions & procedures to compartmentalize and name operations rather than repeating lines of code.