Professional Documents
Culture Documents
Table of Contents
DEFINITION OF PROBLEM 3
PROBLEM STATEMENT: 3
DESCRIPTION OF PROBLEM: 3
TECHNIQUES OF ANALYSIS 4
STRUCTURE CHART 22
1 | Page
`
CONCLUSION 36
2 | Page
`
DEFINITION OF PROBLEM
PROBLEM STATEMENT:
A business using an outdated system to collect, and store data began having issues with keeping
data safe and complaints of long waiting time since the current process to collect, store and print a bill is
too time-consuming and inefficient. This problem needs to be addressed so as to allow the business to
become more efficient and expand its services. A program must be written so that it would
update/replace an old/obsolete system of data collection and storage. The program must be able to
simplify and optimize the system previously done by the business.
DESCRIPTION OF PROBLEM:
Cheng’s laundromat is a family business run by Mr. Cheng, located in San Fernando. It has been
in business since 1977 by Mr. Cheng and his wife. The laundry offers services to clean clothes brought in
by customers daily. The business still utilizes the same manual method of data collection for collecting
the customer’s details and making a bill. This process has become very problematic for example when
customers bring their laundry, their data is taken and written in a list in a record book. This task is
already strenuous but furthermore, when a customer comes to collect their laundry, the employee
manually looks through the list names for the customer’s details. This makes the expansion of the
laundromat appear unrealistic.
A program should be created to complete all the tasks the business requires in a more efficient
and less stressful manner. The program must store customer details, edit services and generate reports.
This is accomplished by using my knowledge as a Computer Science student.
3 | Page
`
TECHNIQUES OF ANALYSIS
Several techniques of analysis were employed to accurately understand the requirements for the
program. Interviews with management where they can share their vision, questionnaires for
understanding their needs and simply watching business operations were done.
● Can You Summarize What You Want The Program To Do To Me In Just A Few Sentences?
4 | Page
`
5 | Page
`
● Main function- Upon the start of the program, the program will read data from external files and
insert them into arrays. Following that, the user will be shown a menu holding the various tasks
that the program allows.
MENU
1. Bringing to wash
2. Collecting items
3. Change price of wash
4. Report of items in stock
5. Adding a new type of wash
6. CLOSE
The user is then prompted to select one of the options listed above, e.g. either 1, 2, 3
etc. Then the program will then execute the function associated with that option. After the
execution of that option, it displays the menu again followed by the prompt for another option
and then loops back to execute the option. This process continues until the close option is
chosen which will simply write all data in arrays to the appropriate files and closes the program.
● Bill function- prompt for customer name, the wash id that would be done and the amount of items
● When option 1 is chosen data from prices file will be outputted and then the bill function happens.
● When option 2 is chosen the user will be prompted to enter the name of the customer requesting to
claim his/her item(s). upon entering the customer’s name, the program will search the file stock for
the customer’s name, and when/if it is found the customer’s name, number of items and wash
requested will be shown. After this the program will remove the customers details from the stock
and then re-enter the loop, showing the menu and prompting for another option.
● Option 3 is to change the price of a wash, therefore when option 3 is chosen the program will
prompt for the washID of the wash that is wanted to change. The program will then take the washID
and search the prices file for the corresponding price. When the price is found it will be set to zero
and the user prompted for the new price of the wash which will then be stored. Finally, the program
will update the prices file b4 it enters the loop and opens the menu and prompt for another option.
● If option 4 is selected the program will simply print all data from the stock file.
● If option 5 is chosen, the user will be prompted to enter the new washID, its price and a short
description. The program will then store the new wash in the prices file and the reentry to the loop.
6 | Page
`
THE FIGURES BELOW SHOW THE FLOWCHARTS FOR THE FUNCTIONS OF THE PROGRAM
NOTE*
7 | Page
`
8 | Page
`
FIGURE B-MENU
9 | Page
`
FIGURE C-INARRAY
10 | Page
`
FIGURE D- SEARCH
11 | Page
`
FIGURE E- OPTION 1
12 | Page
`
FIGURE F- OPTION 2
13 | Page
`
FIGURE G- OPTION 3
14 | Page
`
FIGURE H- OPTION 4
15 | Page
`
FIGURE I- OPTION 5
16 | Page
`
17 | Page
`
18 | Page
`
19 | Page
`
20 | Page
`
1. The program should be able to create a new customer record which includes
a unique customer id, the customer's name, address, and a telephone contact
number.
2. Must be able to accept either the customer's name or the customer’s ID and
search the customer database for the customer’s details.
3. The program must be able to add a new wash type, this consists of a wash
ID, wash description and the wash price.
4. It should also be able to edit any existing wash type.
5. Finally, the program must generate reports for all files.
Non-functional requirements:
21 | Page
`
STRUCTURE CHART
22 | Page
`
The employer requested a modern and simplistic design. It was also requested to be made for
touch screen devices.
23 | Page
`
SOURCE CODE:
The program was written in Dev C++. An appropriate data structure, indentation and use
of comments were kept in mind. Attached is the source code that was written followed by the 2
files (stock and prices containing test data) that the program would use.
24 | Page
`
INT MAIN:
TEST NUMBER TYPE OF INPUT DESCRIPTION EXPECTED RESULT ACTUAL RESULT SUCCESS? /COMMENTS
1 NORMAL User enters a The appropriate Correct function The test was successful.
value between option function will opens.
1-6. open.
2 EXTREME User enters a Program outputs a Option not The test was successful.
value above the message “Option available.
range (1-6). not available.” and And the loop
the loop continues. continued.
3 ERRONEOUS User enters Program was Program entered an The test was completely
wrong data e.g. expected to be infinite loop. unsuccessful.
“A”. terminated.
TEST 1: SHOWING THAT THE FIRST OPTION WAS SELECTED AND SUCCESSFULLY OPENED.
25 | Page
`
TEST 2: SHOWING THAT A NUMBER OVER THE RANGE WAS SELECTED AND ITS OUTCOME
26 | Page
`
TEST TYPE OF INPUT DESCRIPTION EXPECTED RESULT ACTUAL RESULT SUCCESS? /COMMENTS
1 NORMAL Data entered: “The total is “The total is Yes, successful.
Name- Jackie $30.00” should be $30.00” was
washID- 3 outputted and the printed and the
numitems- 2 loop entered. menu/loop
entered.
2 EXTREME Name- tom hank “The total is “The total is Yes, successful.
washID- 5 $2500.00” should $2500.00” was
numitems- 100 be outputted and printed and the
the loop entered. menu/loop
entered.
3 Name- @1babe The program runs “The total is The data was accepted,
washID- 1 normally. $2000.00” was therefore a success.
numitem-1 printed and the
menu/loop
ERRONEOUS entered.
4 Name- @1babe The program will The data was taken if incorrect washID is
washID-9 freeze and crash the bill was taken the bill uses the
numitem-100 because the calculated to be price as $0.00, causing
washID does not $0.00 an overall bill to b $0.00
exist.
27 | Page
`
28 | Page
`
29 | Page
`
30 | Page
`
31 | Page
`
32 | Page
`
33 | Page
`
34 | Page
`
35 | Page
`
36 | Page
`
CONCLUSION
This basic program, written for the laundromat was written and tested appropriately for a test
integration in the business. The program will be implemented and any kinks that may be found will be
fixed immediately and retested.
37 | Page