You are on page 1of 2

6 Steps in Program Development (Sample)

1. Program Specification Analysis

Program Plan Program Plan → Compute and rate


Available Input Num1, Num2 the sum and average of two
Required Output Sum and Ave integers (variable)
Processing Requirements (formula)
Sum = Num1 + Num2
Ave = Sum/2

2. Program Design

Flow Chart

Start

Sum = 0
Ave = 0

Input: Num1,
Num2

Sum = Num1 + Num2


𝑆𝑢𝑚
Ave = 2

Print, Sum,
Ave

Stop
3. Program Coding

#include<iostream.h>
// My First Program
int main()
{
int NUM1, NUM2;
int SUM;
float AVE;
cout<<"Input First No.";
cin>>NUM1;
cout<<"Input Second No.";
cin>>NUM2;
SUM=NUM1+NUM2;
AVE=SUM/2
cout<<"the sum is";
cout<<SUM;
cout<<"the ave is";
cout<<AVE;
return 0;
}

You might also like