Professional Documents
Culture Documents
Problem solving is a process of transforming the description of a problem into the solution of that
problem by using our knowledge of the problem domain and by relying on our ability to select and
use appropriate problem-solving strategies, techniques and tools. Effective problem solving
technique begins with breaking problem solving into a series of activities called algorithm.
Examples
a. Write an algorithm to convert the length in feet to centimeter.
Inputs to the algorithm:
length in feet
Expected output:
length in centimetre
Algorithm
Enter the length (L)in feet (Lft)
Calculate the length (L) in cm by multiplying Lft with 30
Print Length in cm (Lcm)
Stop
b. Find the area of a Circle of radius r.
Inputs to the algorithm:
Radius r of the Circle.
Expected output:
Area of the Circle
Algorithm:
Start
Input the Radius r of the Circle
Area = PI*r*r // formula to calculate area of a circle
Print Area
Stop
c. Write an algorithm to read two numbers and find their sum.
Inputs to the algorithm:
First num1.
Second num2.
Expected output:
Sum of the two numbers.
Algorithm:
Start
Input the first num1.
Input the second num2.
Sum num1+num2 // summation of two numbers
Print Sum
End