Software development is a multi steps process that involve understanding problems to be solved, designing the solution, coding the software, and testing the software product.
For example, to calculate the parking fee of a public parking lot, how do you go about doing this?
Understanding the problem
The first step you will do is understanding the problem. If you don't understand the problem to be solved, how can you solve the problem? Therefore, a good software building is started with a good understanding of the problem. To understand the problem you need to read the requirements statement carefully. After you understand the problem, you should clarify you understanding with the users and system analysts by asking questions to confirm your understandings.
For example, after reading the requirements statement, you should ask several questions to clarify:
-How the parking fee is calculated?
-Can the parking fee vary depending types of vehicles and time?
-Do they motivate vehicles owners to park for a long time or for short time?
-Are there different rates for different types of vehicles?
-When vehicles should enter or exit the parking lot?
Developing the solution
After you make clarifications regarding your understandings of the problem, you are going about to create a solution to the problem. To solve the problem, there are three tools that you can use--Structure Chart, Pseudo-code, and Flowchart.
Structure Chart is a chart that show all parts and their hierarchical relationships of your program. Each part of the program is called module and in C programming language we call function.
Pseudo-code is part of language. It is used to describe the detail of algorithms. This requires the steps to accomplish the program. Pseudo-code can be a road map for coding the program.
Algorithm Calculate Parking Fee
1. Set parking rates
-For car and duration<=2,crate1=0$
-For car and duration>2, crate2=1$ per hour
-For truck and duration<=2, trate1=1$
-For truck and duration>2, trate2=2$ per hour
-For bus and duration<=2, brate1=2$
-For bus and duration>2, brate2=3$ per hour
2.Read type of vehicle
-c or C for car
-b or B for bus
-t or T for truck
3.Computer parking duration
-Read time in and time out
-If time out<time in, then prompt the user to enter again.
-Computer duration=time out-time in
4.Calculate parking fee
-If v_type=c & duration<=1 then p_fee=crate1
-If v_type=c & duration>1 then p_fee=0+(duration-1)*crate2
-If v_type=t & duration<=2 then p_fee=trate1
-If v_type=t & duration>2 then p_fee=1+(duration-2)*trate2
-If v_type=b & duration<=2 then p_fee=brate1
-If v_type=b & duration>2 then p_fee=2+(duration-2)*brate2
5.Print report: type of vehicle, duration, and parking fee
Flowchart is another way to show the detail steps of the algorithm. In stead of showing the detail using logic language(pseudo-code) the flowchart uses graphical symbols.
Coding the program
Now, it is the time to write code. To code your program, you can use one or the combination of of computer programming languages that you are familiar with. The purpose of this tutorial is to help you understand the software development process, so we don't write the code of this program.
Testing the program
After you complete writing code for your program, you need test it to see whether all parts of your program work well together.
There are two types of testing the program--Blackbox test and Writebox test.
The Blackbox test is conducted by people who do not know what really are in your program. The Blackbox test plan need to be prepared based on the requirements.
Another testing is Whitebox test that is conducted by people who know what really are in your system. If you are the programmer, one of your responsibilities is to conduct this test.