Plus One Computer Application Notes Chapter 3 Principles of Programming and Problem Solving

Students can Download Chapter 3 Principles of Programming and Problem Solving Notes, Plus One Computer Application Notes helps you to revise the complete Kerala State Syllabus and score more marks in your examinations.

Kerala Plus One Computer Application Notes Chapter 3 Principles of Programming and Problem Solving

Problem-solving using computers:
It has no intelligent quotient. Hence they are slaves arid human beings are the masters. It can’t make its own decisions. They can perform tasks based upon the instructions given by the humans (programmers).

Approaches in problem-solving
Top-down design: Larger programs are divided into smaller ones and solve each task by performing simpler activities. This concept is known as a top-down design in problem-solving

Bottom-Up design: Here also larger programs are divided into smaller ones and the smaller ones are again subdivided until the lowest level of detail has been reached. We start solving from the lowest module onwards. This approach is called a Bottom-up design.

Phases in programming
1. Problem identification: This is the first phase in programming. The problem must be identified then only it can be solved, for this, we may have to answer some questions. During this phase, we have to identify the data, its type, quantity, and formula to be used as well as what activities are involved to get the desired output is also identified for example if you are suffering from stomach ache and consult a Doctor. To diagnose the disease the doctor may ask you some questions regarding the diet, duration of pain, previous occurrences, etc, and examine some parts of your body by using a stethoscope X-ray, scanning, etc.

2. Deriving the steps to obtain the solution.
There are two methods, Algorithm and flowchart, are used for this.
a) Algorithm: The step-by-step procedure to solve a problem is known as an algorithm. It comes from the name of a famous Arab mathematician Abu Jafer Mohammed Ibn Musaa Al-Khowarizmi, The last part of his name Al-Khowarizmi was corrected to the algorithm.

b) Flowchart: The pictorial or graphical representation of an algorithm is called a flowchart.
Flow chart symbols are explained below
1) Terminal (Oval)
Plus One Computer Application Notes Chapter 3 Principles of Programming and Problem Solving 1
It is used to indicate the beginning and end of a problem

2) Input/Output (parallelogram)
Plus One Computer Application Notes Chapter 3 Principles of Programming and Problem Solving 2
It is used to take input or print output.

3) Processing (Rectangle)
Plus One Computer Application Notes Chapter 3 Principles of Programming and Problem Solving 3
It is used to represent processing That means to represent arithmetic operation such as addition, subtraction, multiplication

4) Decision (Rhombus)
Plus One Computer Application Notes Chapter 3 Principles of Programming and Problem Solving 4
It is used to represent decision making. It has one entry flow and two exit flows but one exit path will be executed at a time.

5) Flowlines (Arrows)
Plus One Computer Application Notes Chapter 3 Principles of Programming and Problem Solving 5
It is used to represent the flow of operation

6) Connector
Plus One Computer Application Notes Chapter 3 Principles of Programming and Problem Solving 6

3. Coding: The dummy codes (algorithm) or flowchart is converted into a program by using a computer language such s Cobol, Pascal, C++, VB, Java, ….. etc.

4. Translation: The computer only knows machine language. |t does not know HLL, but the human beings HLL is very easy to write programs. Therefore a translation’ is needed to convert a program written in HLL into machine code (object code). During this step, the syntax errors of the program will be displayed. These errors are to be corrected and this process will be continued till we get a “No errors” message. Then it is ready for execution.

5. Debugging: The program errors are called ‘bugs’ and the process of detecting and correcting errors is called debugging. In general, there are two types of errors syntax errors and logical errors. When the rules or syntax of the language are not followed then syntax errors occurred and it is displayed after compilation. When the logic of a program is wrong then logical errors occurred and it is not displayed after compilation but it is displayed in the execution and testing phase.

6. Execution and Testing: In this phase, the program will be executed and give test data for testing the purpose of this is to determine whether the result produced by the program is correct or not. There is a chance of another type of error, Run time error, this may be due to inappropriate data.

7. Documentation: It is the last phase in I programming. A computerized system must be documented properly and it is an ongoing process that starts in the first phase and continues till its implementation. It is helpful for the modification of the program later.