Problm Solving
Problm Solving
Lecture # 1
Flowchart Uses:
Shows steps of an algorithm
Used to understand the flow of program
Used to improve the logic for problem solving
Can be reviewed and debugged easily
Flowchart
elements
Example 1
Example 2
A company plans to pay bonus to their employees, the details are
given below:
Those earning Rs. 30,000 or above are to be paid 20 percent of
their salary.
Practice Those earning less than Rs. 30,000 are to be paid Rs. 1000.
The input records contain the employee number, name and salary
Example of the employees.
The output to be printed should contain the employee number,
name, amount of bonus and new salary to be paid to each
employee.
• HINT: Formula to calculate Bonus is: