0% found this document useful (0 votes)
4 views22 pages

Program Design

The document outlines the programming process, detailing the stages from defining a problem to documenting and maintaining a program. It emphasizes the importance of algorithms and pseudocode in program design, as well as the role of programmers in coding and testing. Learning outcomes include understanding the programming process and methods of program design.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views22 pages

Program Design

The document outlines the programming process, detailing the stages from defining a problem to documenting and maintaining a program. It emphasizes the importance of algorithms and pseudocode in program design, as well as the role of programmers in coding and testing. Learning outcomes include understanding the programming process and methods of program design.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

SLIIT CITY UNI

FCIT – Semester 1

PROGRAM DESIGN
Charunika Dampalessa

SLIIT CITY UNI PVT LTD. © 2024 1


Learning Outcomes
End of this lecture you will be able to learn ,

LO1 : Discuss the stages in the programming process.

LO2 : Discuss the methods of Program Design.

SLIIT CITY UNI PVT LTD. © 2024 2


What is a Computer Program?
• Computers, although quite sophisticated electronically, are, nevertheless,

unintelligent.

• In order for them to carry out a task, they must be instructed how to complete the

task.

• Instructions must be given in a language that the computer understands.

SLIIT CITY UNI PVT LTD. © 2024 3


What is a Computer Program?
•Computer Program is a series of instructions to carry out a particular task written in

a language that the computer understands.

SLIIT CITY UNI PVT LTD. © 2024 4


SLIIT CITY UNI PVT LTD. © 2024 5
What does a Programmer do?

SLIIT CITY UNI PVT LTD. © 2024


6
Steps in Program Development

1 2 3 4 5 6 7

Step 1 : Step 2 : Step 3 : Step 4 : Test Step 5 : Step 6 : Run Step 7 :


Define the Outline the Develop the the Code the the program Document
problem solution outline into algorithm algorithm on the and maintain
an algorithm for into a specific computer the program
correctness programming
language

SLIIT CITY UNI PVT LTD. © 2024 7


Step One : Define the problem
• the problem until you understand completely what is required.
• The problem should be divided into three separate components:
 The inputs
 The outputs
 The processing steps to produce the required outputs.
•A is recommended in this analysis phase, as it helps to separate and
define the three components.

SLIIT CITY UNI PVT LTD. © 2024


8
SLIIT CITY UNI PVT LTD. © 2024 9
SLIIT CITY UNI PVT LTD. © 2024 10
Step Two : Outline Solution( Design/Plan Solution )
•Once the problem has been defined, you may decide to break it down into smaller tasks or steps, and
establish a solution outline.
•This initial outline is usually a rough draft of the solution and may include:




•The solution outline may also include a .

SLIIT CITY UNI PVT LTD. © 2024 11


Step Three : Develop the outline into an
algorithm
• The solution outline is then expanded into an algorithm:

• A set of precise steps that describe exactly the tasks to be performed and the
order in which they are to be carried out.
 (a form of structured English) is one method of
representing the solution algorithm.

 is more pictorial method of algorithm representation.

SLIIT CITY UNI PVT LTD. © 2024 12


Flow Chart and Pseudocode Example:

SLIIT CITY UNI PVT LTD. © 2024 13


Step Four : Test Algorithm for correctness
• The main purpose of desk checking
Test data needs to be walked through each step in the algorithm to check that
the instructions described in the algorithm will actually do what they are
supposed to.
• The programmer ‘walks’ through the logic of the algorithm, exactly as a
computer would, keeping track of all major variables on a sheet of paper.

SLIIT CITY UNI PVT LTD. © 2024 14


Step Five : Code the algorithm into a specific
programming language

• Express the algorithms (flowcharts/ pseudo codes) in .

• Software Engineer is responsible for this.

• The source codes and comments can be considered as the documentation

generated at this stage.

SLIIT CITY UNI PVT LTD. © 2024


15
Step Six : Run the program on the computer
• This step uses a program compiler and programmer-designed test data to machine test

the code for syntax errors and logical error.

• This is usually the in the program development process.

• This step may need to be performed several times until you are satisfied that the

program is running as required.

SLIIT CITY UNI PVT LTD. © 2024


16
SLIIT CITY UNI PVT LTD. © 2024 17
Step Seven : Document and maintain the program
• Includes both (such as hierarchy charts, the solution algorithm and
test data results) and that may have been coded in the program.
•Program maintenance refers to changes that may need to be made to a program
throughout its life.
•If the program has been well designed using structured programming techniques, the
code will be seen as self documenting, resulting in easier maintenance.

SLIIT CITY UNI PVT LTD. © 2024


18
What is an algorithm ?

• A set of

• Developed to describe the processes necessary to produce the desired output from

a given input.

SLIIT CITY UNI PVT LTD. © 2024


19
What is a pseudo code?
•Pseudocode is structured English.
 Statements are written in simple English.

 Each instruction is written on a separate line.

 Keywords and indentation are used to signify particular control structures.

 Each set of instructions is written from top to bottom, with only one entry and one
exit.

 Groups of statements may be formed into modules, and that module given a name.

SLIIT CITY UNI PVT LTD. © 2024 20


Summary
•What is a Computer Program?

•What does a Programmer do?

•The Programming Process

•What is an algorithm ?

•What is pseudo code?


SLIIT CITY UNI PVT LTD. © 2024
21
Thank you!

SLIIT CITY UNI PVT LTD. © 2024 22

You might also like