Total Pageviews

Sunday, January 06, 2013

DIFFERENCE BETWEEN TOP-DOWN AND BOTTOM-UP APPROACH

TOP-DOWN APPROACH:

In Top-down approach, first, the main function is designed and progresses down towards the lowest level subsystems. When designing brand new system, Top-down approach is followed. Its advantage is that, it is easy to visualize, provide sense of completeness and easy to understand the progress at any stage.
Disadvantage includes, it may not help much in unit testing and there're chances of redundant business logics.

Here, an overview of the system is first formulated, specifying but not detailing any 1st level subsystems. Each subsystem is then redefined in yet greater detail, sometimes in many additional subsystem levels, until the entire specification is reduced to base elements.

Procedural programming languages like C tend towards top-down as it is started with a function and adding up to it.


BOTTOM-UP APPROACH:

In Bottom-up approach, lowest level modules or subsystems are first developed and progresses upwards to the main function. It is used in Reverse Engineering process which requires analysing someone's design. Its advantage is strong business logic, ability to write good unit testing code and modifications can be performed easily. Its disadvantage is that it requires a lot of effort in writing test cases and programs can't be verified easily in the mid-stage.

Here, the individual base elements of the system are first specified in great detail. These elements are then linked to form larger subsystem.

OOP(Eg: C++, Java) tend to start from bottom, growing up, as it is begun with objects.


The reality is seldom one or the other approach but a combination of both.

Thanks for reading my blog... :-) Do comment about my blog... ;-)

No comments:

Post a Comment