Introduction to the Program Development Life Cycle (PDLC)
Introduction to the Program Development Life Cycle (PDLC)
Source: Computers in your Future © 2002 by Bryan Pfaffenberger
At the dawn of the modern computer era, no notion of managing the software development process existed. Programs were written for well-defined purposes, such as calculating missile trajectories. If the program didn’t work, the programmer corrected it, so this approach came to be known as code-and-fix (or “cut-an-run,” as detractors put it).
When businesses began using computers for more-complex purposes, problems appeared. Often, it turned out that programmers didn’t really understand what managers wanted the program to do, and correcting problems turned into an expensive, time-consuming nightmare. Other problems appeared, too: programmers didn’t document their programs well (if at all), and some developed idiosyncratic programming styles so that they could assure their continued employment, since no one else could figure out what their code did! These early programs were almost impossible to debug and maintain (especially if the original programmer had left the company).
To address these, problems, the program development life cycle was introduced in the 1970s, and is still in widespread use today.
Program Development Life Cycle (A part of SDLC’s implementation phase and provides an organized plan for breaking down the task of program development into manageable chunks, each of which must be successfully completed before moving on to the next phase).
• Defining the problem (The system analyst defines the program specifications)
o Program Specifications
▪ The Input Data
▪ The processing that should occur
▪ What the output should look like
▪ How the user interface should look
• Designing the program (Specifies the components that make the program work)
o Identify the Main Routine – the program’s major activity
o Break down the main routine various components into smaller subroutines (modules)
▪ Control Structures
• Sequence control structure
• Selection control structure
• Repetition control structure
o Developing the Algorithm
o Developing design tools
▪ Structure (hierarchy) charts
▪ Flowchart or pseudocode
• Coding the program (Translating the algorithm into specific program language instructions)
• Testing and debugging the program (Eliminating all errors – visible and hidden. Some errors, however, will surface only when the system is put into use.)
• Formalizing the solution (Documenting the program both internally and externally)
o Internal Documentation (usually through comments as part of the program)
o External Documentation
▪ Description of files that the program needs to work with
▪ Layouts of output that the program produces
▪ Algorithm Design Tools
▪ Instruction Manual
• Overview of the program’s functionality
• Tutorials for beginning users
• In-depth explanations of major program features
• Reference documentation of all program commands
• Thorough description of the error messages generated by the program.
• Implementing and maintaining the program (The programming team fixes program errors that users discover)
o Discovering program errors that weren’t caught in the testing phase
o Periodically evaluating by asking whether the program is fulfilling its objectives that may lead to
▪ modifications to update the program,
▪ add features for the user, or
▪ a decision to abandon the current system and develop a new one.
Program Development Life Cycle (An outline of each of the steps used to build software applications.)
Source: Visual Basic 6 Introductory Concepts and Techniques by Shelly, Cashman, Repede & Mick
1. Analyze the problem.
a. Precisely define the problem to be solved
b. Write the program specifications – descriptions of the program’s inputs, processing, outputs, and user interface.
2. Design the program.
a. Develop a detailed logic plan using a tool such as pseudocode, flowcharts, object structure diagrams, or event diagrams to group the program’s activities into modules.
b. Devise a method of solution or algorithm for each module.
c. Test the solution algorithms.
3. Code the program.
a. Translate the design into an application using a programming language or application development tool by creating a user interface and writing code
b. Include internal documentation – comments and remarks within the code that explain the purpose of code statements.
4. Test and debug the program.
a. Test the program, finding and correcting errors (debugging) until it is error free and contains enough safeguards to ensure desired results.
5. Formalize the solution.
a. Review and, if necessary, revise internal documentation
b. Formalize and complete end-user (external) documentation
6. Maintain the program.
a. Provide education and support to end users
b. Correct any unanticipated errors that emerge and identify user-requested modifications(enhancements)
c. Once errors or enhancement are identified, the program development life cycle begins again in Step 1.
Program Development Cycle
Source: An Introduction to Programming Using VB 6.0 Update 4th Edition © 2004, by David I Scheider
1. Analyze: Define the problem.
Be sure you understand what the program should do – that is, what the output should be. Have a clear idea of what data (or input) are given and the relationship between the input and the desired output.
2. Design: Plan the solution to the problem.
Develop the algorithm (a logical sequence of precise steps that solve the problem). Every detail, including obvious steps, should appear in the algorithm. Translate the algorithm into a logic plan using any of the popular methods – flowcharts, pseudocode, top-down charts. These design tools help the programmer break a problem into a sequence of small tasks the computer can perform to solve the problem. Planning also involves using representative data to test the logic of the algorithm by hand to ensure that it is correct.
3. Choose the interface: Select the objects (text boxes, command buttons etc.)
Determine how the input will be obtained and how the output will be displayed. Then create objects to receive the input and display the output. Also, create appropriate command buttons and menus to allow the user to control the program.
4. Code: Translate the algorithm/flowchart/pseudocode into a programming language.
During this stage, the program is written in a particular language (e.g., Visual Basic) and entered into the computer. The programmer/coder uses the algorithm/flowchart/pseudocode devised in Step 2 along with a knowledge of the programming language, say, Visual Basic.
5. Test and debug. Locate and remove any errors in the program.
As the program is typed, Visual Basic points out certain types of program errors. Other types will detected by Visual Basic when the program is executed; however, many errors due to typing mistakes, flaws in the algorithm, or incorrect usages of the Visual Basic language rules can be uncovered and corrected only by careful detective work. An example of such an error would be using addition when multiplication was the proper operation.
6. Complete the documentation: Organize all the material that describes the program.
Documentation is intended to allow another person, or the programmer at a later date, to understand the program. Internal documentation consists of statements in the program that are not executed, but point out the purposes of various parts of the program. Documentation might also consist of a detailed description of what the program does and how to use the program (for instance, what type of input is expected). For commercial programs, documentation includes an instruction manual and on-line help. Other types of documentation are the flowchart, pseudocode, and top-down chart that were used to construct the program. Although documentation is listed as the last step in the program development cycle, it should take place as the program is being coded.
Program Development Cycle
I. Identify, specify, or determine the Problem.
II. Analyze the Problem.
1. Determine the data/info to be produced (output) as a solution of the problem. Variables required to represent the output should also be defined as part of this step.
2. Determine the data (called inputs) necessary to produce the outputs. As in Step a, variables required to represent the input should be defined.
3. Develop an algorithm for obtaining the outputs from the inputs in a finite number of steps.
Algorithm. An organized sequence of operations for solving a problem in a finite number of steps. In the case of numerical problems, the algorithm consists of the sequence of calculations necessary to obtain the desired outputs, but in the case of non-numerical problems, the algorithm may include various text and graphics manipulation operations along with numerical operations.
The main purpose of this step (Step II) is to make sure that you thoroughly understand the problem. Remember: Any misconceptions in your problem analysis will be carried over into your program. You can't expect a computer to make up for muddled analysis. As the old saying goes: Garbage In = Garbage Out (GIGO)
III. Outline the Program
Formulate the pseudocode, flowchart, structure chart, or other designing tools based on the algorithm.
Pseudocode. A collection of instructions, normally, a mixture of a natural language (usu., English) and a computer programming language (e.g., C Language) that reveal or detail what the program is to be doing.
Flowchart. A chart that shows the path or flow of data through a program or an info-handling system and the operations on the data at significant points along the path.
Structure Chart. A chart that exhibits/expresses the modules or smaller problems and how they are related to each other. Or, simply the vertical slice through the entire problem or system.
IV. Implement the Program
1. Code the Program. Write the source code of the program by translating the design tool (e.g., pseudocode) developed in the preceding step (Step III) into the equivalent statements of the language (e.g., C Language) to be used.
2. Test and debug the Program. Test the operation of the program to track down programming errors (bugs).
3. Document the Program. Include comments which describe the various sections of the program - that is, aside from the External Documentation.
Documentation. A set of instructions shipped with a program or a piece of hardware. It serves as supporting papers on the use, operations, layout or diagram, and requirements of the program or a piece of hardware.
( Technical Documentation - used by programmers and systems analysts to update or modify the program.
♠ Internal Documentation - accomplished by using program comments.
♠ External Documentation - includes flowcharts, decision table, pseudocode, and structure/layout chart that depict input and output program descriptions, and other materials that describe the functions and operations of the program.
( User Documentation describes how to use the program in non-technical terms. It is like an owner's manual for a car or an appliance.
Basic Control Structures (logical constructs that specify how instructions in a program are to be executed)
• Sequence – instructions are designed to be executed (performed by the computer) in the order they are written (i.e., one after another). This control structure provides the building block for computer programs. It is used to show a single action or one action followed in order (sequentially) by another. Actions can inputs, processes, or outputs.
o Example
▪ Go to the phone
▪ Dial the pizza place
▪ Order the pizza
▪ Hang up
• Selection (conditional, branch, or decision) – the program branches off to different instructions depending on whether a condition is met; or, one of several blocks of program code is executed based on a test for some condition. It is used to tell the program which action to take, based on a certain condition. When a condition is evaluated, its result is either true or false. If the result is true, one action is performed; if the result is false, a different action is performed.
o Example
▪ Open your wallet
▪ If you have enough money,
• THEN Go to the phone.
o Dial the pizza place.
o Order the pizza.
o Hang up.
• ELSE Forget the whole thing.
• Repetition (looping or iteration) – the program repeats the same instructions over and over. It is used when a set of actions is to be performed repeatedly.
o Example
▪ DO gobble down pizza
▪ WHILE there is still pizza.
Or
▪ DO gobble down pizza
▪ UNTIL none remains.
• Unconditional Branch – the programs jumps from one place to another. Structured programming forbids this structure.
Some Program Flowcharting Symbols
Symbol Name Meaning
Flowline Used to connect symbols and indicate the flow of logic.
Terminal Used to represent the beginning (Start), the end (End), or a point of interruption or delay in a program.
Input/Output Used for input and output operations, such as reading and printing. Or, represents I/O function, which makes data available for processing (input) or displaying (output) of processed information. The data to be read or printed are described inside.
Processing Used for arithmetic and data-manipulation operations. The instructions are listed inside the symbol. Or, represents the process of executing a defined operation or group of operations that results in a change in value, form, or location of information. Also functions as the default symbol when no other symbol is available.
Decision Used for any logic or comparison operations. Unlike the input/output and processing symbols, which have one entry and one exit flowline, the decision symbol has one entry and two exit paths. The path chosen depends on whether the answer to a question is “yes” or “no.” Or, represents a decision that determines which of a number of alternative paths is to be followed.
Connector Used to join different flowlines. Or, represents any entry from, or exit to, another part of the flowchart.
Off-page Connector Used to indicate that the flowchart continues to a second/next page.
Pre-defined Process Used to represent a group of statements that perform one processing task. Or, represents a named process consisting of one or more operations or program steps that are specified elsewhere.
----- Annotation Used to provide additional info about another flowchart symbol. Or, represents the addition of descriptive info, comments, or explanatory notes as clarification. The vertical line land broken line may be placed on the left, or on the right.
Example Problem:
Suppose you are asked to determine the number of stamps to place on an envelop with the rule or policy that one stamp will be used for every five sheets of paper.
1. Problem Analysis
a. Output Requirements
Description Variable to be Used Data Type
Number of Stamps Stamps Integer
b. Input Requirements
Description Variable to be Used Data Type
Number of Sheets of Paper Sheets Integer
c. Processing Requirements
Compute Stamps = Sheets / 5
Determine the rounded up value of Stamps.
2. Program Design
Algorithm
a. Request or enter number of sheets of paper. (input)
b. Compute number of stamps by dividing the number of sheets by 5. (processing)
c. Round the numbers of stamps up to the next highest whole number. (processing)
d. Display the number of stamps. (output)
Pseudocode
Program: Determine the number of stamps for a letter
Read or Input Sheets
Set the Stamps to Sheets / 5 ( or Compute Stamps = Sheets/5)
Round Stamps up to the next whole number
Display or print Stamps
Program Flowchart
Hierarchy Chart
3. Choosing the Interface
Form Layout
[pic]
Properties Table
Object Properties Setting
Form Name frmStamps
Caption/Text Postage Stamps
BackColor (Choose your own)
Frame/GroupBox Name fraSheetsStamps
Caption/Text Sheets and Stamps
Enabled False
Label Name lblSheets
Caption/Text Number of Sheets
TextBox Name txtSheets
Text (Blank)
Alignment Right Justify
Label Name lblStamps
Caption/Text Number of Stamps
Alignment Right Justify
TextBox Name txtSheets
Text (Blank)
Alignment Right Justify
Locked True
CommandButton/Button Name cmdOn (or btnOn)
Caption &On
CommandButton/Button Name cmdCompute (or btnCompute)
Caption/Text &Compute
Enabled False
CommandButton/Button Name cmdClear (or btnClear)
Caption/Text C&lear
Enabled False
CommandButton/Button Name cmdQuit(or btnQuit)
Caption &Quit
4. Coding the Program
Code 1: In Visual Basic 6.0
Private Sub cmdOn_Click()
If UCase(cmdOn.Caption) = "&ON" Then
fraSheetsAndStamps.Enabled = True
cmdOn.Caption = "&Off"
cmdClear.Enabled = True
Else
fraSheetsAndStamps.Enabled = True
cmdOn.Caption = "&On"
cmdClear.Enabled = False
cmdCompute.Enabled = False
End If
End Sub
Private Sub cmdClear_Click()
txtSheets.Text = Empty
txtStamps.Text = Empty
End Sub
Private Sub cmdCompute_Click()
If Val(txtSheets.Text) Mod 5 > 0 Then
txtStamps.Text = Fix(Val(txtSheets.Text) / 5) + 1
Else
txtStamps.Text = Val(txtSheets.Text) / 5
End If
End Sub
Private Sub cmdQuit_Click()
MsgBox "Hasta que me vuelva a ejecutar...", vbInformation, "Gracias!"
End
End Sub
Private Sub txtSheets_LostFocus()
If Val(txtSheets.Text) ................
................
In order to avoid copyright disputes, this page is only a partial summary.
To fulfill the demand for quickly locating and searching documents.
It is intelligent file search solution for home and business.