0% found this document useful (0 votes)
79 views

Chapter 12 Software Development

The document describes the stages of the program development lifecycle, including analysis, design, coding, testing, and maintenance. It explains that analysis involves identifying requirements, design shows how the program will be developed, coding is writing the program, testing ensures it works as intended, and maintenance fixes errors and adapts the program over time. Structure charts and state-transition diagrams are introduced as tools to model programs during design. Syntax errors are found during coding while logic errors are found in testing. Different types of test data, including normal, abnormal, extreme, and boundary cases, should be used to thoroughly test the program.

Uploaded by

Shubham Gaur
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
79 views

Chapter 12 Software Development

The document describes the stages of the program development lifecycle, including analysis, design, coding, testing, and maintenance. It explains that analysis involves identifying requirements, design shows how the program will be developed, coding is writing the program, testing ensures it works as intended, and maintenance fixes errors and adapts the program over time. Structure charts and state-transition diagrams are introduced as tools to model programs during design. Syntax errors are found during coding while logic errors are found in testing. Different types of test data, including normal, abnormal, extreme, and boundary cases, should be used to thoroughly test the program.

Uploaded by

Shubham Gaur
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 11

CS-AS 9618/22 CHAPTER 12

SOFTWARE DEVELOPMENT

The purpose of a program development lifecycle


In order to develop a successful program or suite of programs that is going
to be used by others to perform a specific task or solve a given problem, the
development needs to be well ordered and clearly documented, so that it can
be understood and used by other developers.
This chapter introduces the formal stages of software (program) development
that are set out in the program development lifecycle.

Stages in the program development lifecycle

MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR


Analysis
The analysis stage often starts with a feasibility study, followed by investigation and fact finding to identify exactly
what is required from the program.
Design
The program specification from the analysis stage is used to show how
the program should be developed. When the design stage is complete, the
programmer should know what is to be done, all the tasks that need to be
completed, how each task is to be performed and how the tasks work together.
Coding
The program or set of programs is written using a suitable programming
language.
Testing
The program is run many times with different sets of test data, to test that
it does everything it is supposed to do in the way set out in the program
design.
Maintenance
The program is maintained throughout its life, to ensure it continues
to work effectively. This involves dealing with any problems that arise
during use, including correcting any errors that come to light, improving
the functionality of the program, or adapting the program to meet new
requirements.

The waterfall model


This linear sequential development cycle is one of the earliest models used,
where each stage is completed and signed off before the next stage is begun.
This model is suitable for smaller projects with a short timescale, for which the
requirements are well known and unlikely to change

MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR


Program design

A structure chart is a modelling tool used in program design to decompose


a problem into a set of sub-tasks. The structure chart shows the hierarchy or
structure of the different modules and how they connect and interact with each
other. Each module is represented by a box and the parameters passed to and
from the modules are shown by arrows pointing towards the module receiving the
parameter

Purpose and use of structure charts

MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR


MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR
MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR
Purpose and use of state-transition diagrams to
document algorithms
A finite state machine (FSM) is a mathematical model of a machine that can
be in one of a fixed set of possible states. One state is changed to another by
an external input, this is called a transition. A diagram showing the behavior of an FSM is called a
state-transition diagram.

MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR


MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR
Location, identification and correction of errors
Syntax errors are errors in the grammar of a source program. In the coding
phase of the program development lifecycle, programs are either compiled or
interpreted so they can be executed. During this operation, the syntax of the
program is checked, and errors need to be corrected before the program can be
executed.

Logic errors are errors in the logic of a program, meaning the program does not
do what it is supposed to do. These errors are usually found when the program
is being tested. For example, the program in Figure 12.11 will run, but the
results will not be as expected
5<2
123=0

MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR


Program testing
Programs need to be rigorously tested before they are released. Tests begin
from the moment they are written; they should be documented to show that
the program is robust and ready for general use.
There needs to be a test strategy set out in the set out in the analysis stage of the program
development lifecycle showing an overview of the testing required to meet
the requirements specified.
During the program design stage, pseudocode is written. This can be tested
using a dry run, in which the developer works through a program or module
from a program manually and documents the results using a trace table.

MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR


MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR
Several types of test data need to be used during testing:
» Normal test data that is to be accepted by a program and is used to show
that the program is working as expected.
» Abnormal test data that should be rejected by a program as it is unsuitable
or could cause problems.
» Extreme test data that is on the limit of that accepted by a program; for
example, when testing a validation rule such as number >= 12 AND
number <= 32 the extreme test data would be 12 at the lower limit and
32 at the upper limit; both these values should be accepted.
» Boundary test data that is on the limit of that accepted by a program or
data that is just outside the limit of that rejected by a program;
for example, when testing a validation rule such as number >= 12 AND
number <= 32 the boundary test data would be 12 and 11 at the lower
limit and 32 and 33 at the upper limit; 12 and 32 should be accepted,
11 and 33 should be rejected.

Program maintenance
Program maintenance is not like maintaining a piece of equipment by replacing
worn out parts. Programs do not wear out, but they might not work correctly in
unforeseen circumstances. Logic or run-time errors that require correction may
occur from time to time, or users may want to use the program in a different way.
Program maintenance can usually be divided into three categories:
» Corrective maintenance is used to correct any errors that appear during
use, for example trapping a run-time error that had been missed during
testing.
» Perfective maintenance is used to improve the performance of a program
during its use, for example improving the speed of response.
» Adaptive maintenance is used to alter a program so it can perform any new
tasks required by the customer, for example working with voice commands as
well as keyboard entry.

MINHAJAKHTAR MINHAJ AKHTAR +923322397921 /MINHAJAKHTAR

You might also like