CIS 3100 Structured Programming

Some problems by their very nature do not fit the

This preview shows 2 out of 4 pages.

Some problems by their very nature do not fit the model that top-down program design is based upon. Their solution cannot be expressed easily in a particular sequence of instructions. When the order in which instructions are to be executed cannot be determined in advance, easily, a different approach is required. Top-down design was therefore combined with bottom-up design . In bottom-up design, the approach is to start “at the bottom”, with problems that have already been solved and for which a reusable software component might exist. From this position, the software engineer works upwards towards a solution to the overall problem. It is important in this approach that the reusable components are as “modular” as possible. A module is a component of a larger system that interacts with the rest of the system in a simple and well-defined manner. The idea is that a module can be “plugged into” a system. The details of what goes on inside a module are not important to the system as a whole, only that the module fulfils its function correctly. For example, a module might contain procedures to print a list of students, to add a new student, edit a student’s details and to return a list of specified students. How the module stores the master records of student details is hidden from applications/systems that use this module. Similarly, the detail of how the various procedures are coded is also hidden. This is called information hiding . It is one of the most important principles of software engineering. Applications only require knowledge of what procedures are available from the module and the data that can be accessed. This information is published. It is often called the module’s interface or interfaces . Dr K R Bond 2000
Image of page 2

Subscribe to view the full document.

A common format for a software module is a module containing some data, along with some subroutines (subprograms/procedures/functions) for manipulating that data. The data itself is often hidden from view inside the module forcing a program using the module to manipulate the data indirectly, by calling the subroutines provided by the module for this purpose. The advantages of this approach are as follows: the data is protected, since it can be manipulated only in known, well-defined ways; it is easier to write programs to use a module because the details of how the data is represented and stored need not be known; the storage structure of the data and the code for the subroutines in a module may be altered without affecting programs that make use of the module as long as the published interfaces and the module’s functionality remain the same. Modules that could support this kind of information-hiding became common in programming languages in the early 1980s. The concept has been developed since then into a central platform of software engineering called object-oriented programming , often abbreviated as OOP .
Image of page 3
Image of page 4
You've reached the end of this preview.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern