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

Algorithm, Flow Chart, Program

The document discusses algorithms, programs, flow charts, loops, and counters as they relate to solving problems on a computer. An algorithm is a step-by-step problem solving procedure that can be carried out by a computer. A program is an algorithm written in a programming language. A flow chart is a pictorial representation of an algorithm's logic. Loops allow for circular repetition of instructions until a condition is met. Counters track repetitions by incrementing a value.

Uploaded by

happy kumar
Copyright
© © All Rights Reserved
Available Formats
Download as RTF, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views

Algorithm, Flow Chart, Program

The document discusses algorithms, programs, flow charts, loops, and counters as they relate to solving problems on a computer. An algorithm is a step-by-step problem solving procedure that can be carried out by a computer. A program is an algorithm written in a programming language. A flow chart is a pictorial representation of an algorithm's logic. Loops allow for circular repetition of instructions until a condition is met. Counters track repetitions by incrementing a value.

Uploaded by

happy kumar
Copyright
© © All Rights Reserved
Available Formats
Download as RTF, PDF, TXT or read online on Scribd
You are on page 1/ 2

INTRODUCTION

As you know that althrough computer is versatile and powerful machine and can do variety of things but
still is does not know what to do its own. Solving problem on computer can be quite complex
phenomenon. A user might make mistake or forget some statements in solving the problem. Thus to
avoid any mistake in program, it should be planned in advance. The logic of problem should be very clear
before you undertake work on computer. Now this logic can be facilitated by use of Algorithm or
Program or Flow Chart

ALGORITHM
Algorithm is a step by step problem solving proceduce that can be carried out by computer. Before
actually developing program in computer language, you can put down logic of program and steps
involved in simple English language. These step by step instructions in simple English sentences is called
algorithm
EXAMPLE
Calculate total marks obtained by student. Marks in three subjects are given to you. To solve this
problem, the following step by step procedure can be used:
STEP 1 Start
STEP2 Read marks in three subjects
call them A, B,C, respectively
STEP 3 Add A, B, C
STEP 4 Write "Total"
STEP5 Stop

PROGRAM
It is set or series of instruction (Algorithm) written in any 'computer programming high level language'
that are fed into computer through input device to perfrom certain task
EXAMPLE
Algorithm writtern above total of three subject marks can converted into program in following ways"
(This program is writtern in computers "BASIC" / High Level-Language)
10 LET A = 80
20 LET B = 55
30 LET C =90
40 LET TOTAL = A+B+C
50 PRINT TOTAL
60 END

FLOW CHART
It is pictorial representation of logic and it is technique of buliding logic on paper. Flow charts are charts
drawn in various shapes of boxes. All these boxes are connected to each other so that sequence of steps
is very much clear to user. We can always draw sequence and steps of program on paper befor trying it
out on computer. This will help anybody to see logic clearly in steps. This drawing can be said to be flow
chart
LOOPS
As it is clear from name LOOP, it is circular repetition of one or more instructions which countinuous till
certain condition is met to terminate it. Looping greatly reduces number of instructions which are being
repeated in program

COUNTERS
It means repetitions. Since computer never gets tired, in program where you are not incriminating value
of counter, it will never meet terminating condition and go it endless LOOP. We can increment value of
COUNTER by any number. For example to print even number (2, 4, 6), since difference between number
is 2, we will increment value of COUNTER by 2
EXAMPLE
Count = Count + (Increment Value)
Count = 2
Count = Count + Count
Measure = 2+2
Count = 2+2

You might also like