0% found this document useful (0 votes)
232 views107 pages

Fastfood Automation

The document provides an overview of a project for a fast food management system. It includes acknowledgements, a table of contents, and sections on problem definition, objectives, and feasibility study. The problem definition discusses automating the manual process of day-to-day fast food activities. The objectives aim to introduce more user friendliness and accessibility of records. The feasibility study evaluates the economic, technical, operational and schedule feasibility of the project.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
232 views107 pages

Fastfood Automation

The document provides an overview of a project for a fast food management system. It includes acknowledgements, a table of contents, and sections on problem definition, objectives, and feasibility study. The problem definition discusses automating the manual process of day-to-day fast food activities. The objectives aim to introduce more user friendliness and accessibility of records. The feasibility study evaluates the economic, technical, operational and schedule feasibility of the project.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 107

FASTFOOD

MANAGMENT
SYSTEM

SUBMITTED BY:

ACKNOWLEDGEMENT
With Candor and Pleasure I take opportunity to
express my sincere thanks and obligation to my
esteemed guide Mr.G.S.Baluja . It is because of
his able and mature guidance and co-operation
without which it would not have been possible
for me to complete my project.
It is my pleasant duty to thank all the staff
member of the computer center who never
hesitated me from time during the project.
Finally, I gratefully acknowledge the support,
encouragement & patience of my family, And as
always, nothing in my life would be possible
without God, Thank You!

TABLE OF CONTENT
1. Preface
2. System Study
2.1. Introduction
2.2. Feasibility Study
2.3. System Overview
3. System Analysis
3.1. Importance of Computerized
FASTFOOD MANAGMENT System
3.2. About the Project
3.3. Functional Requirements
4. System Design
4.1. System Development Cycle
4.2. Context Level DFD
4.3. DFD for Car Renting System
4.4. Search Process
5. Data Dictionary
5.1. Physical Design
5.2. Source Code

6. Testing
6.1. Testing Phases
6.2. Verification & Validation
6.3. Reports
7. System Implementation
8. Post Implementation Maintenance and Review
9. Users Manual
9.1. Operational instruction for the User
9.2. Introduction to various operations
10. Bibliography

PROBLEM DEFINITION
1.1 INTRODUCTION TO THE PROBLEM:
This is a Project work undertaken in context of partial fulfillment of the BIT. Since
FASTFOOD is associated with the lives of common people and their day to day routines
so I decided to work on this project. The manual handling of the record is time

consuming and highly prone to error. The purpose of this project is to


automate the process of day to day activities. The user can inputs codes of
items he wants to purchase and receives a bill. The activities like purchasing,
see menu, add items, modify item records, delete items and finally receiving
total bill can be performed easily. And finally a report is generated through
totaling the expenses and been showed in the form of a balance sheet.
I found two main key-points to design and programmed my project using
TURBO C++ and its FILES facility as database storage. First, Because
TURBO C++ compiler has the ability to debug the project at run time and
gives appropriate error messages if it found in the project at run time. Its
help is too enough to learn and study any function of a particular header file
using the keyboard Keys (Ctrl + F1) to keep the cursor on that particular
function. Second.
I have tried my best to make the complicated process of FASTFOOD
MANAGEMENT System as simple as possible using Structured & Modular
technique & Menu oriented interface. I have tried to design the software in
such a way that user may not have any difficulty in using this package &
further expansion is possible without much effort. Even though I cannot
claim that this work to be entirely exhaustive, the main purpose of my
exercise is perform each resturants activity in computerized way rather than
manually which is time consuming.
I am confident that this software package can be readily used by nonprogramming personal avoiding human handled chance of error.

1.2 NEED:
I have designed the given proposed system in the C++ to automate the
process of car renting.

The complete set of rules & procedures related to renting a car and
generating report is called FASTFOOD MANAGEMENT SYSTEM. My
project gives a brief idea regarding automated renting a car activities.
The following steps that gives the detailed information of the need of
proposed system are:

Performance:

During past several decades, the car renting system is


supposed to maintain manual handling of all the renting activities. The
manual handling of the record is time consuming and highly prone to error.
To improve the performance of the car renting system, the computerized car
renting system is to be undertaken. The computerized project is fully
computerized and user friendly even that any of the members can see the
report and status of the car.

Efficiency:

The basic need of the project is efficiency. The project


should be efficient so that whenever a new item is added, or item is modified
or deleted the menu is updated automatically. And if any item is purchased,
the bill is generated according to purchase.

Control:

The complete control of the project is under the hands of


authorized person who has the password to access this project and illegal
access is not supposed to deal with. All the control is under the administrator
and the other members have the rights to just see the records not to change
any transaction or entry.

Security:

Security is the main criteria for the proposed system. Since


illegal access may corrupt the database. So security has to be given in this
project.

Software: Software includes the platform where the car renting project is
being prepared. I have done my project using DOS based Compiler TURBO
C++ platform and the database is the FILE HANDLING MECHANISM OF
TURBO C++. But it is not necessary that we have to first install Turbo C++
to run this project.

OBJECTIVE
During the past several decades personnel function has been
transformed from a relatively obscure record keeping staff to
central and top level management function. There are many factors
that have influenced this transformation like technological
advances, professionalism, and general recognition of human
beings as most important resources.
A computer based management system is designed to handle all the
primary information required to calculate bill which include item
of purchase. Separate database is maintained to handle all the
details required for the correct statement calculation and
generation.
This project intends to introduce more user friendliness in the
various activities such as record updation, maintenance, and
searching. The searching of record has been made quite simple as
all the details of the customer can be obtained by simply keying in
the identification of that customer. Similarly, record maintenance
and updation can also be accomplished by using the identification
of customer with all the details being automatically generated.
These details are also being promptly automatically updated in the
master file thus keeping the record absolutely up-to-date.
The entire information has maintained in the database or Files and
whoever wants to retrieve cant retrieve, only authorization user
can retrieve the necessary information which can be easily be
accessible from the file.
The main objective of the entire activity is to automate the process
of day to day activities of purchasing a item from fast food corner.

FEASIBILITY STUDY
The feasibility study proposes one or more conceptual solution to the
problem set of the project. In fact, it is an evaluation of whether it is
worthwhile to proceed with project or not.
Feasibility analysis usually considers a number of project alternatives, one
that is chosen as the most satisfactory solution. These alternatives also need
to be evaluated in a broad way without committing too many resources.
Various steps involved in feasibility analysis are:
1. To propose a set of solution that can realize the project goal. These
solutions are usually descriptions of what the new system should look
like.
2. Evaluation of feasibility of such solutions. Such evaluation often
indicates shortcomings in the initial goals. This step is repeated as the
goals are adjusted and the alternative solutions are evaluated.
Four primary areas of interest in feasibility study are:
Economic Feasibility: An evaluation of development cost weighed against
the ultimate income of benefit derived from the development system of
product. In economic feasibility, cost benefit analysis is done in which
expected cost and benefits are evaluated.

COST AND BENEFIT ANALYSIS

Developing an IT application is an investment. Since after developing that


application it provides the organization with profits. Profits can be monetary
or in the form of an improved working environment. However, it carries
risks, because in some cases an estimate can be wrong. And the project
might not actually turn out to be beneficial.
Cost benefit analysis helps to give management a picture of the cost,
benefits and risks. It usually involves comparing alternate investments.
Cost benefit determines the benefits and savings that are expected from the
system and compares them with the expected costs.
In performing cost and benefit analysis it is important to identify cost and
benefits factors. Cost and benefits can be categorized into the following
categories:
1.

Development Costs

2.

Operating Costs

Development costs is the costs that are


incurred during the development of the system. It is one time investment.
Operating Costs are the expenses required for
the day to day running of the system. Examples of Operating Costs are
Wages, Supplies and Overheads.

3. Hardware/Software Costs It includes the cost of purchasing


or leasing of computers and its peripherals. Software costs involves
required S/W costs.
4.

Personnel Costs

5.

Facility Costs Expenses that are incurred during the preparation of

It is the money spent on the people involved in


the development of the system.

the physical site where the system will be operational. These can be
wiring, flooring, acoustics, lightning, and air-conditioning.
6. Supply Costs These are variable costs that are very
proportionately with the amount of use of paper, ribbons, disks, and the
like.

BENEFITS

We can define benefits as

Profit or Benefit = Income Costs


Benefits can be accrued by:
Increasing income, or
Decreasing costs, or
Both

Technical Feasibility:
Technical Feasibility includes existing and new H/W and S/W requirements
that are required to operate the project on the platform Turbo C++. The basic
S/W requirement is TURBO C++ in which the front end of the hospital
management project has been done. The basic entry forms are developed in
TURBO C++ and the data is stored in the FILES.

Operational Feasibility:
Operational feasibility is mainly concerned with issues like whether the
system will be used if it is developed and implemented. Whether there will
be resistance from users that will effect the possible application benefits?
The essential questions that help in testing the technical feasibility of a
system are following:
Does management support the project?
Are the users not happy with current business practices? Will it reduce
the time considerably? If yes, then they will welcome the change and the
new system.
Have the users involved in the planning and development of the project?
Early involvement reduced the probability of resistance towards the new
system.

Will the proposed system really benefit the organization? Does the
overall response increase? Will accessibility of information be lost? Will
the system effect the customers in considerable way?

Legal Feasibility:
A determination of any infringement, violation, or liability that could result
from development of the system. Legal feasibility tells that the software
used in the project should be original purchased from the legal authorities
and they have the license to use it or the software are pirated.

Alternatives:
An evaluation of alternative approaches to the development of system or
product.

Cost and Benefit Analysis of fast food restaurant

Costs:
Cost
Software
Turbo C++
Windows
NT
Server
Windows 98
Hardware
Central Computer
Client Machine
Development
Analyst
Developer
Training
Data Entry
Warranty (1 month)
Professional
TOTAL COST

Cost per unit

Quantity

Cost

3,000
30,000
15,000
4,000

1
1
1
2

3,000
30,000
15,000
8,000

100,000
50,000

1
4

1,00,000
2,00,000

50,000
20,000
20,000
5,0000

1
2
1
1

50,000
40,000
20,000
5,000

20,000
4,91,000

20,000

According to the fast food management System, Rs. 250 is to be charged


from the customer and Rs. 450 is charged for the waiters salary and the
sales tax charged is Rs. 30.
Expected increase in the number of customers: 40 per month and number of
customer for local is: 150 per day.
Let the amount collected from operations in a month: 250,000 for a month.
Amount collected from the customer when he returns car this year
=12*(40 * (250 + 450) + 150 * 30 * 30 + 250000)
=Rs. 49,56,000
For three years = 3 * 4956,000
= Rs. 1,48,68,000
Now using Net Present Value Method for cost benefit analysis we have,

Net Present Value (origin) = Benefits Costs


=14868000-491000
=Rs. 14377000
gain % = Net Present Value / Investment
=14377000/491000
=29.28%
Overall gain = 2928% in five year
For each year
1st year:
Investment = 491,000
Benefit = 49,56,000
Net Present Value for first year = 4956000-491000
=4965000
gain%=4965000/491000
=909.36% in first year
2nd year:
Investment = 491,000
Benefit = 10412,000
Net Present Value for first year = 10412000-491000
=9921000
gain%=9921000/491000
=2020.57% at the end of second year
3rd year:
Investment = 491,000
Benefit = 15859000
Net Present Value for first year = 15859000-491000
=15368000
gain%=15368000/491000
=3129.93% at the end of third year

From cost and benefit analysis we have found that the project is
economically feasible since it is showing great gains (approx. above
3000%).
After economic feasibility, technical feasibility is done. In this, major issue
is to see if the system is developed what is the likelihood that itll be
implemented and put to operation? Will there be any resistance from its
user?
It is clear that the new automated system will work more efficiently and
faster. So the users will certainly accept it. Also they are being actively
involved in the development of the new system. So our system is
operationally feasible.
After the feasibility study has been done and it is found to be feasible, the
management has approved this project.

FACT FINDING TECHNIQUES


The functioning of the system is to be understood by the system analyst to
design the proposed system. Various methods are used for this and these are
known as fact-finding techniques. The analyst needs to fully understand the
current system.
The analyst needs data about the requirements and demands of the project
undertaken and the techniques employed to gather this data are known as
fact-finding techniques. Various kinds of techniques and the most popular
among them are interviews, questionnaires, record views, case tools and also
the personal observations made by the analyst himself.

Interviews

Interview is a very important data gathering technique as in this the analyst


directly contacts system and the potential user of the proposed system.
One very essential aspect of conducting the interview is that the interviewer
should first establish a rapport with the interviewee. It should also be taken
into account that the interviewee may or may not be a technician and the
analyst should prefer to use day to day language instead of jargon and
technical terms.
The advantage of the interview is that the analyst has a free hand and the he
can extract almost all the information from the concerned people but then as
it is a very time consuming method, he should also employ other means such
as questionnaires, record reviews, etc. This may also help the analyst to
verify and validate the information gained. Interviewing should be
approached, as logically and from a general point of view the following
guides can be very beneficial for a successful interview:
1. Set the stage for the interview.
2. Establish rapport; put the interview at ease.
3. Phrase questions clearly and succinctly.
4. Be a good listener; a void arguments.
5. Evaluate the outcome of the interview.
The interviews are of the two types namely structured and unstructured.

I . Structured Interview
Structured interviews are those where the interviewee is asked a standard set
of questions in a particular order. All interviews are asked the same set of
questions. The questions are further divided into two kinds of formats for
conducting this type if interview.

II. Unstructured Interview


The unstructured interviews are undertaken in a question-and-answer format.
This is of a much more flexible nature than the structured and can be very
rightly used to gather general in formation about the system.

Questionnaires:

Questionnaires are another way of information gathering where the potential


users of the system are given questionnaires to be filled up and returned to
the analyst.
Questionnaires are useful when the analyst need to gather information from
a large number of people. It is not possible to interview each individual. Also
if the time is very short, in that case also questionnaires are useful. If the
analyst guarantees the anonymity of the respondent then the respondent
answers the questionnaires very honestly and critically.
The analyst should sensibly design and frame questionnaires with clarity of
its objective so as to do just to the cost incurred on their development and
distribution.

Record Reviews

Records and reports are the collection of information and data accumulated
over the time by the users about the system and its operations. This can also
put light on the requirements of the system and the modifications it has
undergone. Records and reports may have a limitation if they are not up-todate or if some essential links are missing. All the changes, which the system
suffers, may not be recorded. The analyst may scrutinize the records either at

the beginning of his study which may give him a fair introduction about the
system and will make him familiar with it or in the end which will provide
the analyst with a comparison between what exactly is/was desired from the
system and its current working.

On-Site Observation

On-site observations are one of the most effectively tools with the analyst
where the analyst personally goes to the site and discovers the functioning of
the system. As a observer, the analyst can gain first hand knowledge of the
activities, operations, processes of the system on-site, hence here the role of
an analyst is of an information seeker. This information is very meaningful
as it is unbiased and has been directly taken by the analyst. This exposure
also sheds some light on the actual happenings of the system as compared to
what has already been documented, thus the analyst gets closer to system.
This technique is also time-consuming and the analyst should not jump to
conclusions or draw inferences from small samples of observation rather the
analyst should be more patient in gathering the information. This method is
however less effective for learning about peoples perceptions, feelings and
motivations.

ANALYSTS INTERVIEW WITH


ADMINISTRATOR
Analyst:

Hi, I have come to talk to you regarding the functioning


of your fast food management project.
Administrator: hello, do come in. I was expecting you.

Analyst:

Ill come straight to the point. Dont hesitate; you can be


as much open you want. There are no restrictions.
Administrator: Ill give you my whole contribution.

Analyst:

Tell me are you excited about the idea of having an


automated system for your fast food management?
Administrator: Yes, I do. Very much. After all its gonna reduce our
loads of work.

Analyst:
Will you elaborate on it?
Administrator: Major problem is managing the status whether item is
available and details about each item like name and cost
of item . There are so many items and the numbers of
customers. At the time of purchasing items, it becomes
more difficult to handle many customers and generating
bill of their purchases.

Analyst:
What do you think be ideal solution to this?
Administrator: All the information of items of menu, customers and cost
of items should be put into computer. Itll be easy for us
to know cost of item and generate bill according to
purchase of item by customer.

Analyst:
Could you explain how?
Administrator: Look whenever a new customer comes by reading menu
he can order items and according to cost of item and
number of items purchases bill is generated.

Analyst:
Do you have different customers categories?
Administrator: No we dont have categorization for customers.
Analyst:
How do you categorize your items?
Administrator: By item number .
Analyst:

Do you have any other expectations or suggestion for the


new system?
Administrator: It should be able to produce reports faster.

Analyst:

Reports? I completely forgot about them. What reports


you people produce presently?
Administrator: Well first is for items in the menu and report about bill of
the customer.

Analyst:
Do you have some format for them?
Administrator: Yes we do have and we want that the same format be
used by the new system.

Analyst:
Yes well take care of that. Any other suggestions?
Administrator: No. You have already covered all the fields.
Analyst:
Thanks for your co-operation. It was nice talking to you.
Administrator: My pleasure. Bye.

QUESTIONNAIRES FOR STAFF


Instructions: Answer as specified by the format. Put NA for non-application situation.

1. What are your expectations out of the new system (computerized)? Rate
the following on a scale of 1-4 giving allow value for low priority.
(a) better cataloguing
(b) better managing of users
(c) better account and patients management
(d) computer awareness
(e) any other________________
2. How many users are you expecting?
____________________________
3. How many items are there?
____________________________
4. How you want the items to be categorized for searching (like by id no.,
by name)?
____________________________
5. Is there any difference in the roles (privileges) of two or more customers?
Yes/No Please specify if Yes
___________________________________________________________
_____________________________________
6. Do you want facility of taking order and reserving seats from phone in
advance?
Yes/No
7. Do you have data of customers entered into some kind of database?
Yes/No
8. How do you want users to be categorized?
_______________________or
_______________________

9. Would you like online registration for users rather than the printed form?
Yes/No
10.Do you already have some existing categorization of customers on the
basis as specified in question 4 above?
Yes/No
11.Any other specific suggestion/expectation out of the proposed system.
___________________________________________________________
_________________________________________

SYSTEM OVERVIEW
The limited time and resources have restricted us to incorporate, in this
project, only a main activities that are performed in a FAST FOOD
MANAGMENT System, but utmost care has been taken to make the system
efficient and user friendly. FAST FOOD MANAGMENT System has been
designed to computerized the following functions that are performed by the
system:

1. ITEMS Detail Functions


a) Adding a New ITEM
b) Modification to ITEM
c) Deleting ITEM.

2. Customers Detail Functions


a) Admission of New customer
b) Item purchased by customer.

3. Report/Details Functions
a) Statement of Items Details
a.1) Availability of a item
a.2) Cost of item
b) Total number of Customers
c) Individual Customer Report

IMPORTANCE OF COMPUTERIZED
RESTURANT SYSTEM
There are several attributes in which the computer based information
works. Broadly the working of computer system is divided into two main
groups:
Transaction System
Decision Support System

Transaction System:
A transaction is a record of some well-defined single and usually small
occurrence in a system. Transactions are input into the computer to
update the database files. It checks the entering data for its accuracy. This
means that numeric data appears in numeric field and character data in
character field. Once all the checks are made, transaction is used to
update the database. Transaction can be inputted in on-line mode or batch
mode. In on-line mode, transactions are entered and updated into the
database almost instantaneously. In batch mode, transactions are
collected into batches, which may be held for a while and inputted later.

Decision Support System:


It assists the user to make analytical decision. It shows the various data in
organized way called analysis. This analysis can be made to study
preferences and help in making decisions.
Computer system works out best with record maintenance. It will tell you
which customer would get how much pending/reports statements. It will
also help to search the information about a particular person by simply
entering his telephone number.
User can store information as per requirement, which can be used for
comparison with other reports.

FUNCTION DETAILS
The basic objective of FAST FOOD MANAGMENT SYSTEM is to
generalize and simplify the monthly or day to day activities of
Purchasing like Admission of New items, modify item or deleting item
purchasing a item according to item available in menu an according to
purchase generating the bill which has to be performed repeatedly on regular
basis. To provide efficient, fast, reliable and user-friendly system is the

basic motto behind this exercise.


Let us now discuss how different functions handle the structure and data
files:

1. Function NEW_ITEM()
This is the function used to add a new item in a menu for a customer
so that he/she can purchase a new item. In that screen, the automatic
item is created.

2. Function MODIFY_ITEM()
This function is used to modify the item number and name in the
menu and list of the items in the restaurant.

3. Function DELETE_ITEM()
This function is used to delete the item from the menu of the
restaurant, then the item record will be deleted from the
database and transferred the record of the deleted item to
another table of database so that the Fast food Management
has the record of deleted items to fulfill his legal liabilities.

4. Function GENERATE_BILL()
When any item is purchased, its bill is generated automatically by
calculating the number of the items purchased and cost of item .

5. Function DISPLAY_RECORD()
This function is used to display all the transaction including the item
name, its cost. And the bill which is generated according to the
purchase of item by customer. This is a global report to display all the
transaction records in the screen.

TESTING
Standard C and Pre-Standard C
1989 Standard C is widespread enough now that it is ok to use its features in new
programs. There is one exception: do not ever use the "trigraph" feature of Standard C.

1999 Standard C is not widespread yet, so please do not require its features
in programs. It is ok to use its features if they are present. However, it is
easy to support pre-standard compilers in most programs, so if you know
how to do that, feel free. If a program you are maintaining has such support,
you should try to keep it working.
To support pre-standard C, instead of writing function definitions in standard
prototype form,
int
foo (int x, int y)
...
Write the definition in pre-standard style like this,
int
foo (x, y)
int x, y;
...
and use a separate declaration to specify the argument prototype:
int foo (int, int);
You need such a declaration anyway, in a header file, to get the benefit of
prototypes in all the files where the function is called. And once you have
the declaration, you normally lose nothing by writing the function definition
in the pre-standard style.
This technique does not work for integer types narrower than int. If you
think of an argument as being of a type narrower than int, declare it as int
instead.

There are a few special cases where this technique is hard to use. For
example, if a function argument needs to hold the system type dev_t, you
run into trouble, because dev_t is shorter than int on some machines; but
you cannot use int instead, because dev_t is wider than int on some
machines. There is no type you can safely use on all machines in a nonstandard definition. The only way to support non-standard C and pass such
an argument is to check the width of dev_t using Autoconf and choose the
argument type accordingly. This may not be worth the trouble.
In order to support pre-standard compilers that do not recognize prototypes,
you may want to use a preprocessor macro like this:
/* Declare the prototype for a general external
function. */
#if defined (__STDC__) || defined (WINDOWSNT)
#define P_(proto) proto
#else
#define P_(proto) ()
#endif

Conditional Compilation
When supporting configuration options already known when building your
program we prefer using if (... ) over conditional compilation, as in
the former case the compiler is able to perform more extensive checking of
all possible code paths.
For example, please write
if (HAS_FOO)
...
else
...
instead of:
#ifdef HAS_FOO
...
#else
...

#endif
A modern compiler such as GCC will generate exactly the same code in both
cases, and we have been using similar techniques with good success in
several projects.
While this is not a silver bullet solving all portability problems, following
this policy would have saved the GCC project alone many people hours if
not days per year.
In the case of function-like macros like REVERSIBLE_CC_MODE in GCC
which cannot be simply used in if( ...) statements, there is an easy
workaround.
Simply
introduce
another
macro
HAS_REVERSIBLE_CC_MODE as in the following example:
#ifdef REVERSIBLE_CC_MODE
#define HAS_REVERSIBLE_CC_MODE 1
#else
#define HAS_REVERSIBLE_CC_MODE 0
#endif

Formatting Error Messages


Error messages from compilers should look like this:
Source-file-name:lineno: message
If you want to mention the column number, use one of these formats:
Source-file-name:lineno:column: message
Source-file-name:lineno.column: message
Line numbers should start from 1 at the beginning of the file, and column numbers should
start from 1 at the beginning of the line. (Both of these conventions are chosen for
compatibility.) Calculate column numbers assuming that space and all ASCII printing
characters have equal width and assuming tab stops every 8 columns.

In an interactive program (one that is reading commands from a terminal), it


is better not to include the program name in an error message. The place to
indicate which program is running is in the prompt or with the screen layout.

(When the same program runs with input from a source other than a
terminal, it is not interactive and would do best to print error messages using
the non-interactive style.)
The string message should not begin with a capital letter when it follows a
program name and/or file name. Also, it should not end with a period.
Error messages from interactive programs, and other messages such as usage
messages, should start with a capital letter. But they should not end with a
period.

FUNCTIONAL REQUIREMENT

The platform is the hardware and software combination that the


Client/Server runs on. While hardware systems vary widely in features and
capabilities, certain common features are needed for the operating system
software.

HARDWARE SPECIFICATIONS
Hardware is a set of physical components, which performs the functions of
applying appropriate, predefined instructions. In other words, one can say
that electronic and mechanical parts of computer constitute hardware.
This package is designed on a powerful programming language C++. It can
run on almost all the popular microcomputers. The following are the
minimum hardware specifications to run this package: -

Processors and memory


The best system to start with is one based on Pentium II with a minimum 32
MB of RAM. Adequate performance requires at least 64 MB of RAM. But
for a database server at least 64 to 128 MB of RAM is required.

Video displays
Earlier, the IBM-compatible computers had a simple text-only monochrome
for the video display. Now, they use the advanced high-resolution color
displays. For Client/Server systems one should have VGA or better video
display.
In the following table TLA stands for the various types of adapters that can
be used with IBM compatible PCs and the standard resolution for each one
of them.

ADAPTER TYPE
TLA
Monochrome
Display MDA
Adapter

STANDARD RESOLUTION
Text only (80 characters by 25
lines)

Color Graphics Adapter


Enhanced
Graphics
Adapter
Video Graphics Array
Super VGA

CGA
EGA

640 200
640 350

VGA 640 480


SVGA 800 600 or 1024 768

Disk Drives
Each client computer must have enough disk space available to store the
client portion of the software and any data files that needs to be stored
locally.
It is best to provide a local disk drive for each client computer. However
Client/Server applications can use the diskless workstations for which the
only disk access is the disk storage located on a network file server. The hard
disk drive at database server should be at least of the capacity 4.1 GB. But it
is recommended to have one of capacity 8.2 GB.

Mouse
A mouse is a must for the client software running under Windows OS or any
other graphical environment.

Keyboard
Each client must have a 104 keys extended keyboard.

SOFTWARE REQUIREMENTS

The software is a set of procedures of coded information or a program which


when fed into the computer hardware, enables the computer to perform the
various tasks. Software is like a current inside the wire, which cannot be
seen but its effect can be felt.
Application software

TURBO C++ [Dos Based]

SYSTEM DEVELOPMENT LIFE


CYCLE

User
Requirement
Requirement
Determinatio
n

Revised Requirement
Specification

Initial
Requirement
Investigatio
n

Decision to
Design Information
System

Feasibi
lity
Analys
is

Feasibility
Study

Test Plan
.
Logical System Design

System
Implementation

Functional Spec.
System
Specific
ation
Analysi
s

System
Design

Physical
Requirement
System

Configuration
Data

Schedule

Budget
System
Evaluation

System Modification
Maintenance

Hardware
Study

Improved System

CONTEXT LEVEL DFD

FAST FOOD MANAGEMENT


SYSTEM

ITEM

CUSTOMER

FASTFOOD
MANAGEMEN
T SYSTEM

GENERATE
BILL

PRINT
DEVICE

DATA FLOW DIAGRAM


ADDING A NEW ITEM

1 Generating
new item no.

ITEM

1.1 Display
Form

FILE

Process

Update Table

1.2 Get
Details

Item Document
1.4
Update

1.3
Open

DATA FLOW DIAGRAM


RECORD MODIFICATION

USER

1
Read the item
number

Scan Record

2
Show the
Details of
Record

Processing

3
Modify
Details of
Record

DATA FLOW DIAGRAM

FILE

Update

LISTING OF ITEMS
FILE
Scan Record

1
Read the
Itemnumbe
r

ITEM

3 Copy
Selected
Record

2 Select
Record
from
Database

Processing

6 Copy
Selected
Record

4
Compute
Total

Processing

Output
5 Select
Record

7
Compute
Bill

8
Generate
Total List

Final Output

To Screen/Printer

OUTPUT
UNIT

DATA FLOW DIAGRAM

GENERATING BILL OF PURCHASE


FILE
Scan bed No

MANAGE
EMENT

1
Read item
number

2 Check
for Item
Update

4
Close
Database

Processing

3
Compute
Bill

Cash

CUSTOM
ER

DATA FLOW DIAGRAM

LIST OF ALL RECORDS


FILE
Scan All Record

MANAG
EMENT

1
Read the
Request

2 Select
Record
from File
Processing

3 Copy
Selected
Record

7 Copy
Selected
Record

Processing

7
Compute
bill

4
Compute
Total
5
Select
Record

Output

8 Generate
Total List
Final Output
To Screen/Printer

OUTPUT
UNIT

System Design
The design document that we will develop during this phase is the blueprint
of the software. It describes how the solution to the customer problem is to
be built. Since solution to complex problems isnt usually found in the first
try, iterations are most likely required. This is true for software design as
well. For this reason, any design strategy, design method, or design
language must be flexible and must easily accommodate changes due to
iterations in the design. Any technique or design needs to support and guide
the partitioning process in such a way that the resulting sub-problems are as
independent as possible from each other and can be combined easily for the
solution to the overall problem. Sub-problem independence and easy
combination of their solutions reduces the complexity of the problem. This
is the objective of the partitioning process. Partitioning or decomposition
during design involves three types of decisions: Define the boundaries along which to break;
Determine into how money pieces to break; and
Identify the proper level of detail when design should stop and
implementation should start.
Basic design principles that enable the software engineer to navigate the
design process suggest a set of principles for software design, which have
been adapted and extended in the following list:
Free from the suffer from "tunnel vision." A good designer should consider
alternative approaches, judging each based on the requirements of the
problem, the resources available to do the job.
The design should be traceable to the analysis model. Because a single
element of the design model often traces to multiple requirements, it is
necessary to have a means for tracking how requirements have been satisfied
by the design model.
The design should not repeat the same thing. Systems are constructed using
a set of design patterns, many of which have likely been encountered before.
These patterns should always be chosen as an alternative to reinvention.
Time is short and resources are limited! Design time should be invested in
representing truly new ideas and integrating those patterns that already exist.
The design should "minimize the intellectual distance" between the software
and the problem as it exists in the real world. That is, the structure of the
software design should (whenever possible) mimic the structure of the
problem domain.

The design should exhibit uniformity and integration. A design is uniform if


it appears that one person developed the entire thing. Rules of style and
format should be defined for a design team before design work begins. A
design is integrated if care is taken in defining interfaces between design
components.
The design activity begins when the requirements document for the software
to be developed is available. This may be the SRS for the complete system,
as is the case if the waterfall model is being followed or the requirements for
the next "iteration" if the iterative enhancement is being followed or the
requirements for the prototype if the prototyping is being followed. While
the requirements specification activity is entirely in the problem domain,
design is the first step in moving from the problem domain toward the
solution domain. Design is essentially the bridge between requirements
specification and the final solution for satisfying the requirements.
The design of a system is essentially a blueprint or a plan for a solution for
the system. We consider a system to be a set of components with clearly
defined behavior that interacts with each other in a fixed defined manner to
produce some behavior or services for its environment. A component of a
system can be considered a system, with its own components. In a software
system, a component is a software module.
The design process for software systems, often, has two levels. At the first
level, the focus is on deciding which modules are needed for the system, the
specifications of these modules, and how the modules should be
interconnected. This is what is called the system design or top-level design.
In the second level, the internal design of the modules, or how the
specifications of the module can be satisfied, is decided. This design level is
often called detailed design or logic design. Detailed design essentially
expands the system design to contain a more detailed description of the
processing logic and data structures so that the design is sufficiently
complete for coding.
Because the detailed design is an extension of system design, the system
design controls the major structural characteristics of the system. The system
design has a major impact on the testability and modifiability of a system,
and it impacts its efficiency. Much of the design effort for designing
software is spent creating the system design.
The input to the design phase is the specifications for the system to be
designed. Hence, a reasonable entry criteria can be that the specifications are
stable and have been approved, hoping that the approval mechanism will
ensure that the specifications are complete, consistent, unambiguous, etc.
The output of the top-level design phase is the architectural design or the

system design for the software system to be built. This can be produced with
or without using a design methodology. A reasonable exit criteria for the
phase could be that the design has been verified against the input
specifications and has been evaluated and approved for quality.
A design can be object-oriented or function-oriented. In function-oriented
design, the design consists of module definitions, with each module
supporting a functional abstraction. In object-oriented design, the modules in
the design represent data abstraction (these abstractions are discussed in
more detail later). In the function-oriented methods for design and describe
one particular methodology the structured design methodology in some
detail. In a function- oriented design approach, a system is viewed as a
transformation function, transforming the inputs to the desired outputs. The
purpose of the design phase is to specify the components for this
transformation function, so that each component is also a transformation
function. Hence, the basic output of the system design phase, when a
function oriented design approach is being followed, is the definition of all
the major data structures in the system, all the major modules of the system,
and how the modules interact with each other.
Once the designer is satisfied with the design he has produced, the
design is to be precisely specified in the form of a document. To specify the
design, specification languages are used. Producing the design specification
is the ultimate objective of the design phase. The purpose of this design
document is quite different from that of the design notation. Whereas a
design represented using the design notation is largely to be used by the
designer, a design specification has to be so precise and complete that it can
be used as a basis of further development by other programmers. Generally,
design specification uses textual structures, with design notation helping in
understanding.

Scheduling
Scheduling of a software project does not differ greatly from scheduling of
any multi- task engineering effort. Therefore, generalized project scheduling
tools and techniques can be applied with little modification to software
projects.
Program evaluation and review technique (PERT) and critical path method
(CPM) are two project scheduling methods that can be applied to software
development. Both techniques are driven by information already developed
in earlier project planning activities.

Estimates of Effort
A decomposition of the product function
The selection of the appropriate process model and task set
Decomposition of tasks
Interdependencies among tasks may be defined using a task network. Tasks,
sometimes called the project Work Breakdown Structure (WBS) are defined
for the product as a whole or for individual functions.
Both PERT and CPM provide quantitative tools that allow the software
planner to (1) determine the critical path-the chain of tasks that determines
the duration of the project; (2) establish "most likely" time estimates for
individual tasks by applying statistical models; and (3) calculate "boundary
times" that define a time window" for a particular task.
Boundary time calculations can be very useful in software project
scheduling. Slippage in the design of one function, for example, can retard
further development of other functions. It describes important boundary
times that may be discerned from a PERT or CPM network: (I) the earliest
time that a task can begin when preceding tasks are completed in the shortest
possible time, (2) the latest time for task initiation before the minimum
project completion time is delayed, (3) the earliest finish-the sum of the
earliest start and the task duration, (4) the latest finish- the latest start time
added to task duration, and (5) the total float-the amount of surplus time or
leeway allowed in scheduling tasks so that the network critical path
maintained on schedule. Boundary time calculations lead to a determination
of critical path and provide the manager with a quantitative method for
evaluating progress as tasks are completed.

Both PERT and CPM have been implemented in a wide variety of automated
tools that are available for the personal computer. Such tools are easy to use
and take the scheduling methods described previously available to every
software project manager.

//*Name: GEC
//Language: C\C++
//Category: Database\Files
//Description: it is like a super-mart where user inputs codes of
items
//he wants to purchase and receives a bill.*//
//****************************************************
******
//
PROJECT FAST-FOOD AUTOMATION
//****************************************************
******
//****************************************************
******
//
INCLUDED HEADER FILES
//****************************************************
******
#include <iostream.h>
#include <fstream.h>
#include <process.h>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include <ctype.h>
#include <conio.h>
#include <dos.h>
//****************************************************
******
//
CLASS NAME : menu
//
DETAILS : IT CONTROLS OVER ALL THE
FUNCTIONS
//****************************************************
******
class menu

{
public :
void main_menu(void) ;
private :
void box(void) ;
void box_for_list(void);
void help(void);
void edit_menu(void) ;
};
//****************************************************
******
//
CLASS NAME : food
//
DETAILS : IT CONTROLS OVER ALL THE
FUNCTIONS
//
RELATED TO FOOD ITEMS
//****************************************************
******
class food
{
public :
void add_item(void) ;
void delete_item(void) ;
void modify_item(void) ;
void list_of_item(void) ;
void purchase(void) ;
private :
int last_code(void) ;
void delete_record(int) ;
void modify_record(int) ;
void display_record(int) ;
int item_found(int) ;
int recordno(int) ;

void sort(void) ;
int itemcode ;
char itemname[30] ;
float itemcost, itemprice ;
};
//****************************************************
******
//
CLASS NAME : account
//
DETAILS : IT CONTROLS OVER ALL THE
FUNCTIONS
//
RELATED TO MAKING BILL
//****************************************************
******
class account
{
public :
void bill_list(void) ;
void prepare_bill(int) ;
int last_billno(void) ;
void add_bill(int, int t_itemcode, char *t_itemname, float t_qty,
float t_cost, float t_price) ;
private :
int code, billno, length ;
int dd, mm, yy ;
float cost, price, quantity ;
char name[30] ;
};
//****************************************************
******
// THIS FUNCTION DRAWS BOX FOR THE MENUS
//****************************************************
******

void menu :: box(void)


{
char c1=178, c2=177, c3=176 ;
int k=1 ;
gotoxy(1,2) ;
for (int i=1; i<=1840; i++)
{
if (k == 1)
cout <<c1 ;
else
if (k == 2)
cout <<c2 ;
else
if (k == 3)
cout <<c3 ;
k++ ;
if (k == 4)
k=1;
}
for (i=5; i<=21; i++)
{
gotoxy(21,i) ;
cout <<"
}
}

";

//****************************************************
******
// THIS CLASS CONTAINS FUNCTIONS RELATED TO DRAW
A BOX ETC.
//****************************************************
******
class shape
{

public :
void line_hor(int, int, int, char) ;
void line_ver(int, int, int, char) ;
void box(int,int,int,int,char) ;
};
//****************************************************
******
// FUNCTION TO DRAW HORIZONTAL LINE
//****************************************************
******
void shape :: line_hor(int column1, int column2, int row, char c)
{
for ( column1; column1<=column2; column1++ )
{
gotoxy(column1,row) ;
cout <<c ;
}
}
//****************************************************
******
// FUNCTION TO DRAW VERTICAL LINE
//****************************************************
******
void shape :: line_ver(int row1, int row2, int column, char c)
{
for ( row1; row1<=row2; row1++ )
{
gotoxy(column,row1) ;
cout <<c ;

}
}
//****************************************************
******
// FUNCTION TO DRAW BOX LINE
//****************************************************
******
void shape :: box(int column1, int row1, int column2, int row2,
char
c)
{
char ch=218 ;
char c1, c2, c3, c4 ;
char l1=196, l2=179 ;
if (c == ch)
{
c1=218 ;
c2=191 ;
c3=192 ;
c4=217 ;
l1 = 196 ;
l2 = 179 ;
}
else
{
c1=c ;
c2=c ;
c3=c ;
c4=c ;
l1 = c ;
l2 = c ;
}

gotoxy(column1,row1) ;
cout <<c1 ;
gotoxy(column2,row1) ;
cout <<c2 ;
gotoxy(column1,row2) ;
cout <<c3 ;
gotoxy(column2,row2) ;
cout <<c4 ;
column1++ ;
column2-- ;
line_hor(column1,column2,row1,l1) ;
line_hor(column1,column2,row2,l1) ;
column1-- ;
column2++ ;
row1++ ;
row2-- ;
line_ver(row1,row2,column1,l2) ;
line_ver(row1,row2,column2,l2) ;
}
//****************************************************
******
// FUNCTION TO DISPLAY HELP ABOUT THE PROJECT
//****************************************************
******
void menu :: help(void)
{
clrscr() ;
shape s ;
s.box(2,1,79,25,218) ;
//textbackground(RED+WHITE) ;
s.box(18,2,62,4,219) ;
textcolor(BLUE+BLINK) ;
textbackground(RED+WHITE) ;

gotoxy(21,3); cprintf("WELCOME TO PROJECT FASTFOOD ") ;


cprintf("AUTOMATION");
textcolor(LIGHTGRAY) ;
delay(10) ;
gotoxy(10,6); cout <<"In this Project you can keep record
of daily consumption" ;
delay(10) ;
gotoxy(10,7); cout <<"of food items. " ;
delay(10) ;
gotoxy(10,9); cout <<" This program is capable of holding
any no. of bills." ;
delay(10) ;
gotoxy(10,11); cout <<"- In the first option you can purchase
the food items" ;
delay(10) ;
gotoxy(10,12); cout <<" enlisted in the menu card." ;
delay(10) ;
gotoxy(10,14); cout <<"- In the second option you can see
the list of all the food items " ;
delay(10) ;
gotoxy(10,16); cout <<"- available.";
delay(10) ;
gotoxy(10,17); cout <<"- Through the third option you can
do editing of the " ;
delay(10) ;
gotoxy(10,19); cout <<"- stored food item (add, modify,
delete)." ;
delay(10) ;
gotoxy(10,20); cout <<"- In the fourth option you can see the
list of all the bills." ;
delay(10) ;
gotoxy(10,22); cout <<"- (NOTE: Bills can be of the last
month also." ;
delay(10) ;

gotoxy(10,24); cout <<"- And the last option is Quit (Exit to


Dos). " ;
delay(10) ;
textcolor(BLUE+BLINK) ;
//textbackground(RED+WHITE) ;
gotoxy(26,25) ; cprintf(" Press any key to continue ") ;
textcolor(LIGHTGRAY) ; //textbackground(RED) ;
gotoxy(25,2) ;
getch() ;
for (int i=25; i>=1; i--)
{
delay(20) ;
gotoxy(1,i) ; clreol() ;
}
}
//****************************************************
******
// THIS FUNCTION DRAWS THE BOX FOR THE LIST OF
FOOD ITEMS
//****************************************************
******
void menu :: box_for_list()
{
shape s ;
s.box(2,1,79,25,218) ;
s.line_hor(3,78,3,196) ;
s.line_hor(3,78,5,196) ;
s.line_hor(3,78,23,196) ;
// textbackground(WHITE) ;
gotoxy(3,4) ;
for (int i=1; i<=76; i++) cprintf(" ") ;
//textbackground(BLACK) ;
textcolor(WHITE) ; //textbackground(WHITE) ;
gotoxy(4,4) ;

cprintf("ITEM CODE
ITEM NAME
ITEM
COST
ITEM PRICE") ;
textcolor(LIGHTGRAY) ;// textbackground(BLACK) ;
int d1, m1, y1 ;
struct date d;
getdate(&d);
d1 = d.da_day ;
m1 = d.da_mon ;
y1 = d.da_year ;
gotoxy(4,2) ;
cout <<"Date: " <<d1 <<"/" <<m1 <<"/" <<y1 ;
}
//****************************************************
******
// THIS FUNCTION CREATE MAIN MENU AND CALLS
OTHER FUNCTIONS
//****************************************************
******
void menu :: main_menu(void)
{
clrscr() ;
char ch ;
while (1)
{
clrscr() ;
// box() ;
// box_for_list();
// help();
// textmode
gotoxy(32,6) ;
cout <<"F A S T F O O D" ;
gotoxy(32,7) ;

cout <<"~~~~~~~~~~~~~~~~" ;
gotoxy(32,9) ;
cout <<"1: PURCHASE" ;
gotoxy(32,11) ;
cout <<"2: SEE MENU" ;
gotoxy(32,13) ;
cout <<"3: EDIT" ;
gotoxy(32,15) ;
cout <<"4: TOTAL BILL" ;
gotoxy(32,17) ;
cout <<"0: QUIT" ;
gotoxy(32,20) ;
cout <<"Enter Choice : " ;
ch = getche() ;
if (ch == 27)
return ;
else
if (ch == '1')
{
food f ;
f.purchase() ;
}
else
if (ch == '2')
{
food f ;
f.list_of_item() ;
}
else
if (ch == '3')
edit_menu() ;
else
if (ch == '4')
{
account a ;

a.bill_list();
}
else
if (ch == '0')
break ;
}
}
//****************************************************
******
// THIS FUNCTION CREATES EDIT MENU AND CALLS
OTHER FUNCTIONS
//****************************************************
******
void menu :: edit_menu(void)
{
char ch ;
while (1)
{
for (int i=5; i<=21; i++)
{
gotoxy(21,i) ;
cout <<"
}
gotoxy(32,6) ;
cout <<"E D I T M E N U" ;
gotoxy(32,7) ;
cout <<"~~~~~~~~~~~~~~~~" ;
gotoxy(32,10) ;
cout <<"1: ADD ITEM" ;
gotoxy(32,12) ;
cout <<"2: MODIFY ITEM" ;
gotoxy(32,14) ;

";

cout <<"3: DELETE ITEM" ;


gotoxy(32,16) ;
cout <<"0: EXIT" ;
gotoxy(32,19) ;
cout <<"Enter Choice : " ;
ch = getche() ;
if (ch == 27)
return ;
else
if (ch == '1')
{
food f ;
f.add_item() ;
break ;
}
else
if (ch == '2')
{
food f ;
f.modify_item() ;
break ;
}
else
if (ch == '3')
{
food f ;
f.delete_item() ;
break ;
}
else
if (ch == '0')
break ;
}
}

//****************************************************
******
// THIS FUNCTION RETURNS THE CODE OF THE LAST
RECORD IN THE
// FOOD FILE (FOOD.DAT).
//****************************************************
******
int food :: last_code(void)
{
fstream file ;
file.open("FOOD.DAT", ios::in) ;
file.seekg(0,ios::beg) ;
int t=0 ;
while (file.read((char *) this, sizeof(food)))
t = itemcode ;
file.close() ;
return t ;
}
//****************************************************
******
// THIS FUNCTION DISPLAY THE LIST OF THE FOOD
ITEMS
//****************************************************
******
void food :: list_of_item(void)
{
clrscr() ;
fstream file ;
file.open("FOOD.DAT", ios::in) ;
file.seekg(0) ;

int row = 6 , found = 0 , pageno = 1 ;


gotoxy(30,2) ;
cout <<"LIST OF ITEMS" ;
gotoxy(29,3) ;
cout <<"~~~~~~~~~~~~~~~" ;
gotoxy(3,4) ;
cout <<"ITEM CODE ITEM NAME
ITEM COST
ITEM PRICE" ;
gotoxy(2,5) ;
cout
<<"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~";
while (file.read((char *) this, sizeof(food)))
{
delay(20) ;
found = 1 ;
gotoxy(5,row) ;
cout <<itemcode ;
gotoxy(14,row) ;
cout <<itemname ;
gotoxy(37,row) ;
cout <<itemcost ;
gotoxy(51,row) ;
cout <<itemprice ;
if ( row == 22 )
{
row = 5 ;
gotoxy(66,1) ;
cout <<"Page no. : " <<pageno ;
gotoxy(66,2) ;
cout <<"===============" ;
pageno++ ;
gotoxy(1,25) ;
cout <<"Press any key to continue..." ;
getche() ;

clrscr() ;
gotoxy(30,2) ;
cout <<"LIST OF ITEMS" ;
gotoxy(3,4) ;
cout <<"ITEM CODE ITEM NAME
COST ITEM PRICE" ;
gotoxy(2,5) ;

ITEM

cout<<"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~" ;
}
else
row++ ;
}
if ( !found )
{
gotoxy(5,10) ;
cout <<"\7Records not found" ;
}
gotoxy(66,1) ;
cout <<"Page no. : " <<pageno ;
gotoxy(66,2) ;
cout <<"===============" ;
gotoxy(1,25) ;
cout <<"Press any key to continue..." ;
getche() ;
file.close () ;
}
//****************************************************
******
// THIS FUNCTION ADD RECORDS IN THE FOOD FILE
(FOOD.DAT)

//****************************************************
******
void food :: add_item(void)
{
int tcode, valid ;
char ch, t_itemcost[10], t_itemprice[10] ;
tcode = last_code() ;
tcode++ ;
do
{
clrscr() ;
gotoxy(71,2) ;
cout <<"<0>=Exit" ;
gotoxy(27,3) ;
cout <<"ADD FOOD ITEM TO THE MENU" ;
gotoxy(26,4) ;
cout <<"~~~~~~~~~~~~~~~~~~~~~~~~~~~" ;
gotoxy(5,6) ;
cout <<"Item Code : " <<tcode ;
gotoxy(5,8) ;
cout <<"Item Name : " ;
gotoxy(5,10) ;
cout <<"Item Cost : " ;
gotoxy(5,12) ;
cout <<"Item Price : " ;
do
{
valid = 1 ;
gotoxy(1,8) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"ENTER ITEM NAME TO ADD IN THE
MENU" ;

gotoxy(5,8) ;
cout <<"Item Name : " ;
gets(itemname) ;
strupr(itemname) ;
if (itemname[0] == '0')
return ;
if ((strlen(itemname) < 1) || (strlen(itemname) >
20))
{
valid = 0 ;
gotoxy(3,24) ;
cout <<"\7 Range = 1..20 (Only letters)" ;
getch() ;
}
} while (!valid) ;
do
{
valid = 1 ;
gotoxy(1,10) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"ENTER ITEM COST TO ADD IN THE
MENU" ;
gotoxy(5,10) ;
cout <<"Item Cost : " ;
gets(t_itemcost) ;
itemcost = atof(t_itemcost) ;
if (t_itemcost[0] == '0')
return ;
if (itemcost < 1 || itemcost > 800)
{
valid = 0 ;
gotoxy(3,24) ;
cout <<"\7 Range = 1..800" ;

getch() ;
}
} while (!valid) ;
do
{
valid = 1 ;
gotoxy(1,12) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"ENTER ITEM PRICE TO ADD IN THE
MENU" ;
gotoxy(5,12) ;
cout <<"Item Price : " ;
gets(t_itemprice) ;
itemprice = atof(t_itemprice) ;
if (t_itemprice[0] == '0')
return ;
if (itemprice < itemcost || itemprice > 1000)
{
valid = 0 ;
gotoxy(3,24) ;
cout <<"\7 Range = "<<itemcost <<"..1000"
;
getch() ;
}
} while (!valid) ;
do
{
gotoxy(1,15) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(5,15) ;
cout <<"Do you want to save this record (y/n) : " ;
ch = getche() ;

ch = toupper(ch) ;
if (ch == '0')
return ;
} while (ch != 'N' && ch != 'Y') ;
if (ch == 'Y')
{
itemcode = tcode ;
fstream file ;
file.open("FOOD.DAT", ios::out | ios::app ) ;
file.write((char *) this, sizeof(food)) ;
file.close() ;
tcode++ ;
}
do
{
gotoxy(1,17) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(5,17) ;
cout <<"Do you want to add more records (y/n) :
";
ch = getche() ;
ch = toupper(ch) ;
if (ch == '0')
return ;
} while (ch != 'N' && ch != 'Y') ;
} while (ch == 'Y') ;
}
//****************************************************
******
// THIS FUNCTION DISPLAY THE RECORD OF THE GIVEN
CODE FROM
// THE FOOD FILE (FOOD.DAT)

//****************************************************
******
void food :: display_record(int tcode)
{
fstream file ;
file.open("FOOD.DAT", ios::in) ;
file.seekg(0,ios::beg) ;
while (file.read((char *) this, sizeof(food)))
{
if (itemcode == tcode)
{
gotoxy(5,3) ;
cout <<"Item Code : "<<itemcode ;
gotoxy(5,4) ;
cout <<"Item Name : "<<itemname ;
gotoxy(5,5) ;
cout <<"Item Cost : "<<itemcost ;
gotoxy(5,6) ;
cout <<"Item Price : "<<itemprice ;
break ;
}
}
file.close() ;
}
//****************************************************
******
// THIS FUNCTION RETURN THE VALUE 1 IF THE RECORD
IS FOUND
// FOR THE GIVEN CODE IN THE FOOD FILE (FOOD.DAT)
//****************************************************
******

int food :: item_found(int tcode)


{
fstream file ;
file.open("FOOD.DAT", ios::in) ;
file.seekg(0,ios::beg) ;
int found=0 ;
while (file.read((char *) this, sizeof(food)))
{
if (itemcode == tcode)
{
found++ ;
break ;
}
}
file.close() ;
return found ;
}
//****************************************************
******
// THIS FUNCTION RETURN THE RECORD NO. OF THE
GIVEN CODE IN
// THE FOOD FILE (FOOD.DAT)
//****************************************************
******
int food :: recordno(int tcode)
{
fstream file ;
file.open("FOOD.DAT", ios::in) ;
file.seekg(0,ios::beg) ;
int found=0 ;
while (file.read((char *) this, sizeof(food)))
{

found++ ;
if (itemcode == tcode)
break ;
}
file.close() ;
return found ;
}
//****************************************************
******
// THIS FUNCTION DELETES THE RECORD FOR THE
GIVEN CODE FROM
// THE FOOD FILE (FOOD.DAT)
//****************************************************
******
void food :: delete_record(int tcode)
{
fstream file ;
file.open("FOOD.DAT", ios::in) ;
fstream temp ;
temp.open("temp.dat", ios::out) ;
file.seekg(0,ios::beg) ;
while ( !file.eof() )
{
file.read((char *) this, sizeof(food)) ;
if ( file.eof() )
break ;
if ( itemcode != tcode )
temp.write((char *) this, sizeof(food)) ;
}
file.close() ;
temp.close() ;
file.open("FOOD.DAT", ios::out) ;

temp.open("temp.dat", ios::in) ;
temp.seekg(0,ios::beg) ;
while ( !temp.eof() )
{
temp.read((char *) this, sizeof(food)) ;
if ( temp.eof() )
break ;
file.write((char *) this, sizeof(food)) ;
}
file.close() ;
temp.close() ;
}
//****************************************************
******
// THIS FUNCTION GIVES THE CODE NO. TO DELETE
RECORD FROM
// THE FOOD FILE (FOOD.DAT)
//****************************************************
******
void food :: delete_item(void)
{
clrscr() ;
char t_code[5], ch ;
int t, tcode ;
gotoxy(3,25) ;
cout <<"Press <ENTER> to see the list" ;
gotoxy(5,3) ;
cout <<"Enter Item Code of the item to be deleted : " ;
gets(t_code) ;
t = atoi(t_code) ;
tcode = t ;
if (t_code[0] == '0')

return ;
if (tcode == 0)
{
list_of_item() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"Press <ENTER> to Exit" ;
gotoxy(5,24) ;
cout <<"Enter Item Code of the item to be deleted : " ;
gets(t_code) ;
t = atoi(t_code) ;
tcode = t ;
if (tcode == 0)
return ;
}
clrscr() ;
if (!item_found(tcode))
{
gotoxy(5,5) ;
cout <<"\7Record not found" ;
getch() ;
return ;
}
display_record(tcode) ;
do
{
gotoxy(1,8) ; clreol() ;
gotoxy(5,8) ;
cout <<"Do you want to delete this record (y/n) : " ;
ch = getche() ;
ch = toupper(ch) ;
} while (ch != 'N' && ch != 'Y') ;
if (ch == 'N')
return ;
delete_record(tcode) ;

gotoxy(5,15) ;
cout <<"\7Record Deleted" ;
getch() ;
}
//****************************************************
******
// THIS FUNCTION MODIFY THE RECORD FOR THE GIVEN
CODE FROM
// THE FOOD FILE (FOOD.DAT)
//****************************************************
******
void food :: modify_record(int tcode)
{
int recno ;
recno = recordno(tcode) ;
int valid, t_code ;
char ch, t_itemcost[10], t_itemprice[10], t_itemcode[5] ;
gotoxy(71,2) ;
cout <<"<0>=Exit" ;
gotoxy(5,12) ;
cout <<"Item Code : " ;
gotoxy(5,14) ;
cout <<"Item Name : " ;
gotoxy(5,16) ;
cout <<"Item Cost : " ;
gotoxy(5,18) ;
cout <<"Item Price : " ;
do
{
gotoxy(20,12) ; clreol() ;
cout <<"Change (y/n) : " ;
ch = getche() ;

ch = toupper(ch) ;
if (ch == '0')
return ;
} while (ch != 'N' && ch != 'Y') ;
valid = 0 ;
while (ch == 'Y' && !valid)
{
valid = 1 ;
gotoxy(1,12) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"ENTER ITEM CODE TO ADD IN THE
MENU" ;
gotoxy(5,12) ;
cout <<"Item Code : " ;
gets(t_itemcode) ;
t_code = atoi(t_itemcode) ;
if (t_code == 0)
return ;
if (item_found(t_code) && t_code != tcode)
{
valid = 0 ;
gotoxy(3,24) ;
cout <<"\7 CODE ALREADY GIVEN" ;
getch() ;
}
}
if (ch == 'N')
t_code = tcode;
do
{
gotoxy(20,14) ; clreol() ;
cout <<"Change (y/n) : " ;
ch = getche() ;

ch = toupper(ch) ;
if (ch == '0')
return ;
} while (ch != 'N' && ch != 'Y') ;
valid = 0 ;
while (ch == 'Y' && !valid)
{
valid = 1 ;
gotoxy(1,14) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"ENTER ITEM NAME TO ADD IN THE
MENU" ;
gotoxy(5,14) ;
cout <<"Item Name : " ;
gets(itemname) ;
strupr(itemname) ;
if (itemname[0] == '0')
return ;
if ((strlen(itemname) < 1) || (strlen(itemname) > 20))
{
valid = 0 ;
gotoxy(3,24) ;
cout <<"\7 Range = 1..20" ;
getch() ;
}
}
do
{
gotoxy(20,16) ; clreol() ;
cout <<"Change (y/n) : " ;
ch = getche() ;
ch = toupper(ch) ;
if (ch == '0')

return ;
} while (ch != 'N' && ch != 'Y') ;
valid = 0 ;
while (ch == 'Y' && !valid)
{
valid = 1 ;
gotoxy(1,16) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"ENTER ITEM COST TO ADD IN THE
MENU" ;
gotoxy(5,16) ;
cout <<"Item Cost : " ;
gets(t_itemcost) ;
itemcost = atof(t_itemcost) ;
if (t_itemcost[0] == '0')
return ;
if (itemcost < 1 || itemcost > 800)
{
valid = 0 ;
gotoxy(3,24) ;
cout <<"\7 Range = 1..800" ;
getch() ;
}
}
do
{
gotoxy(20,18) ; clreol() ;
cout <<"Change (y/n) : " ;
ch = getche() ;
ch = toupper(ch) ;
if (ch == '0')
return ;
} while (ch != 'N' && ch != 'Y') ;

valid = 0 ;
while (ch == 'Y' && !valid)
{
valid = 1 ;
gotoxy(1,18) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"ENTER ITEM PRICE TO ADD IN THE
MENU" ;
gotoxy(5,18) ;
cout <<"Item Price : " ;
gets(t_itemprice) ;
itemprice = atof(t_itemprice) ;
if (t_itemprice[0] == '0')
return ;
if (itemprice < itemcost || itemprice > 1000)
{
valid = 0 ;
gotoxy(3,24) ;
cout <<"\7 Range = "<<itemcost <<"..1000" ;
getch() ;
}
}
do
{
gotoxy(1,21) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(5,21) ;
cout <<"Do you want to save this record (y/n) : " ;
ch = getche() ;
ch = toupper(ch) ;
if (ch == '0')
return ;

} while (ch != 'N' && ch != 'Y') ;


if (ch == 'N')
return ;
itemcode = t_code ;
cout <<"\n" <<itemname ;
cout <<itemcost ;
cout <<itemprice ;
getch() ;
fstream file ;
file.open("FOOD.DAT", ios::out | ios::ate) ;
int location ;
location = (recno-1) * sizeof(food) ;
file.seekp(location) ;
file.write((char *) this, sizeof(food)) ;
file.close() ;
sort() ;
clrscr() ;
gotoxy(5,15) ;
cout <<"\7Record Modified" ;
getch() ;
}
//****************************************************
******
// THIS FUNCTION GIVES THE CODE NO. TO MODIFY
RECORD FROM
// THE FOOD FILE (FOOD.DAT)
//****************************************************
******
void food :: modify_item(void)
{
clrscr() ;
char t_code[5], ch ;

int t, tcode ;
gotoxy(3,25) ;
cout <<"Press <ENTER> to see the list" ;
gotoxy(5,3) ;
cout <<"Enter Item Code of the item to be Modify : " ;
gets(t_code) ;
t = atoi(t_code) ;
tcode = t ;
if (t_code[0] == '0')
return ;
if (tcode == 0)
{
list_of_item() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"Press <ENTER> to Exit" ;
gotoxy(5,24) ;
cout <<"Enter Item Code of the item to be modify : " ;
gets(t_code) ;
t = atoi(t_code) ;
tcode = t ;
if (tcode == 0)
return ;
}
clrscr() ;
if (!item_found(tcode))
{
gotoxy(5,5) ;
cout <<"\7Record not found" ;
getch() ;
return ;
}
display_record(tcode) ;
do
{

gotoxy(5,8) ;
cout <<"Do you want to Modify this record (y/n) : " ;
ch = getche() ;
ch = toupper(ch) ;
} while (ch != 'N' && ch != 'Y') ;
if (ch == 'N')
return ;
modify_record(tcode) ;
}
//****************************************************
******
// THIS FUNCTION SORT THE RECORD IN THE FOOD FILE
(FOOD.DAT)
// ACCORDING TO THE CODE NOS.
//****************************************************
******
void food :: sort(void)
{
int i=0,j ;
food arr[100] ;
food temp ;
fstream file ;
file.open("FOOD.DAT", ios::in) ;
file.seekg(0,ios::beg) ;
while (file.read((char *) &arr[i], sizeof(food)))
i++ ;
int size ;
size = i ;
file.close() ;
for (i=1; i<size; i++)
for (j=0; j<size-i; j++)
{

if (arr[j].itemcode > arr[j+1].itemcode)


{
temp=arr[j];
arr[j]=arr[j+1];
arr[j+1]=temp;
}
}
file.open("FOOD.DAT", ios::out) ;
for (i=0; i<size; i++)
file.write((char *) &arr[i], sizeof(food)) ;
file.close() ;
}
//****************************************************
******
// THIS FUNCTION PURCHASES THE FOOD ITEM IN THE
MENU
//****************************************************
******
void food :: purchase(void)
{
clrscr() ;
account a ;
int t_billno, purchased=0 ;
t_billno = a.last_billno() ;
t_billno++ ;
char t_code[5], ch, t_quantity[5] ;
int t, tcode, i=0, valid ;
float qty ;
int t_itemcode ;
float t_qty, t_cost, t_price ;
char t_itemname[30] ;
struct date d;

int d1, m1, y1 ;


getdate(&d);
d1 = d.da_day ;
m1 = d.da_mon ;
y1 = d.da_year ;
do
{
clrscr() ;
gotoxy(3,25) ;
cout <<"Press <ENTER> to see the list" ;
gotoxy(5,3) ;
cout <<"Enter Item Code of the item to be Purchase : " ;
gets(t_code) ;
t = atoi(t_code) ;
tcode = t ;
if (t_code[0] == '0')
{
if (purchased)
a.prepare_bill(t_billno) ;
return ;
}
if (tcode == 0)
{
list_of_item() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"Press <ENTER> to Exit" ;
gotoxy(5,24) ;
cout <<"Enter Item Code of the item to be
Purchase : " ;
gets(t_code) ;
t = atoi(t_code) ;
tcode = t ;
if (tcode == 0)
{

if (purchased)
a.prepare_bill(t_billno) ;
return ;
}
}
clrscr() ;
if (!item_found(tcode))
{
gotoxy(5,5) ;
cout <<"\7Item Code not found" ;
getch() ;
if (purchased)
a.prepare_bill(t_billno) ;
return ;
}
gotoxy(60,2) ;
cout <<"Date:" <<d1 <<"/" <<m1 <<"/" <<y1 ;
display_record(tcode) ;
do
{
valid = 1 ;
gotoxy(1,8) ; clreol() ;
gotoxy(1,24) ; clreol() ;
gotoxy(1,25) ; clreol() ;
gotoxy(3,25) ;
cout <<"ENTER QUANTITY TO BE
PURCHASE IN Kg." ;
gotoxy(5,8) ;
cout <<"Quantity : " ;
gets(t_quantity) ;
qty = atoi(t_quantity) ;
if (t_quantity[0] == '0')
{
if (purchased)
a.prepare_bill(t_billno) ;

return ;
}
if (qty < 1 || qty > 800)
{
valid = 0 ;
gotoxy(3,24) ;
cout <<"\7 Range = 1..800" ;
getch() ;
}
} while (!valid) ;
do
{
gotoxy(5,10) ; clreol() ;
gotoxy(5,10) ;
cout <<"Do you want to cancel this purchase (y/n)
:";
ch = getche() ;
ch = toupper(ch) ;
} while (ch != 'N' && ch != 'Y') ;
if (ch == 'N')
{
purchased = 1 ;
fstream file ;
file.open("FOOD.DAT", ios::in) ;
file.seekg(0,ios::beg) ;
while (file.read((char *) this, sizeof(food)))
{
if (itemcode == tcode)
{
t_itemcode = itemcode ;
strcpy(t_itemname,itemname) ;
t_cost = itemcost ;
t_price = itemprice ;
t_qty = qty ;

a.add_bill(t_billno,t_itemcode,t_itemname,t_qty,t_cost,t_price) ;
i++ ;
break ;
}
}
file.close() ;
}
do
{
gotoxy(5,12) ; clreol() ;
gotoxy(5,12) ;
cout <<"Do you want to purchase more (y/n) : " ;
ch = getche() ;
ch = toupper(ch) ;
} while (ch != 'N' && ch != 'Y') ;
} while (ch == 'Y') ;
a.prepare_bill(t_billno) ;
}
//****************************************************
******
// THIS FUNCTION RETURNS THE BILL NO. OF THE LAST
RECORD
// IN THE BILL FILE (BILL.DAT)
//****************************************************
******
int account :: last_billno(void)
{
fstream file ;
file.open("BILL.DAT", ios::in) ;
file.seekg(0,ios::beg) ;
int t=0 ;

while (file.read((char *) this, sizeof(account)))


t = billno ;
file.close() ;
return t ;
}
//****************************************************
******
// THIS FUNCTION ADDS THE RECORD IN THE BILL FILE
(BILL.DAT)
//****************************************************
******
void account :: add_bill(int t_billno, int t_itemcode, char
t_itemname[30], float t_qty, float t_cost, float t_price)
{
struct date d;
int d1, m1, y1 ;
getdate(&d);
d1 = d.da_day ;
m1 = d.da_mon ;
y1 = d.da_year ;
dd = d1 ;
mm = m1 ;
yy = y1 ;
code = t_itemcode ;
strcpy(name,t_itemname) ;
cost = t_cost ;
price = t_price ;
quantity = t_qty ;
billno = t_billno ;
fstream file ;
file.open("BILL.DAT", ios::out | ios:: app ) ;
file.write((char *) this, sizeof(account)) ;

file.close() ;
}
//****************************************************
******
// THIS FUNCTION PREPARES AND DISPLAYS THE BILL
FOR THE
// GIVEN BILL NO. ACCORDING TO PURCHASES MADE.
//****************************************************
******
void account :: prepare_bill(int t_billno)
{
clrscr() ;
struct date d;
int d1, m1, y1 ;
getdate(&d);
d1 = d.da_day ;
m1 = d.da_mon ;
y1 = d.da_year ;
float total=0.0, total_bill=0.0 ;
gotoxy(33,3) ;
cout <<"CUSTOMER BILL" ;
gotoxy(32,4) ;
cout <<"~~~~~~~~~~~~~~~" ;
gotoxy(55,5) ;
cout <<"Date:" <<d1 <<"/" <<m1 <<"/" <<y1 ;
gotoxy(8,7) ;
cout <<"ITEMS PURCHASED" ;
gotoxy(8,8) ;
cout <<"~~~~~~~~~~~~~~~" ;
gotoxy(8,9) ;
cout <<"Item code Item name
Cost Price Qty
Total" ;

gotoxy(8,10) ;
cout<<"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~" ;
int row=11 ;
fstream file ;
file.open("BILL.DAT", ios::in) ;
file.seekg(0) ;
while (file.read((char *) this, sizeof(account)))
{
if (billno == t_billno)
{
gotoxy(8,5) ;
cout <<"BILL NO. # " <<billno ;
gotoxy(8,6) ;
cout <<"~~~~~~~~~~~~~~~" ;
gotoxy(10,row) ;
cout <<code ;
gotoxy(18,row) ;
cout <<name ;
gotoxy(39,row) ;
cout <<cost ;
gotoxy(47,row) ;
cout <<price ;
gotoxy(56,row) ;
cout <<quantity ;
total = quantity * price ;
gotoxy(63,row) ;
cout <<total ;
total_bill = total_bill + total ; // this bill give
total of each item
row++ ;
}
}
file.close() ;

gotoxy(39,row+1) ;
cout <<"TOTAL BILL: Rs." <<total_bill <<" /=" ;
getch() ;
}
//****************************************************
******
// THIS FUNCTION DISPLAYS THE LIST OF THE BILLS
//****************************************************
******
void account :: bill_list(void)
{
clrscr() ;
fstream file ;
file.open("BILL.DAT", ios::in) ;
file.seekg(0) ;
int row=5, found=0, pageno=1, prev_billno=0, flag=0 ;
float total=0.0, total_bill=0.0 ;
gotoxy(30,2) ;
cout <<"LIST OF BILLS" ;
gotoxy(29,3) ;
cout <<"~~~~~~~~~~~~~~~" ;
gotoxy(3,4) ;
cout <<"Billno. Date Item Code Item name Cost Price
Qty Total" ;
gotoxy(3,5) ;
cout<<"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~";
while (file.read((char *) this, sizeof(account)))
{
row++ ;
delay(20) ;

found = 1 ;
if (prev_billno != billno)
{
if (flag)
{
gotoxy(52,row) ;
cout <<"TOTAL BILL: Rs." <<total_bill
<<"/=" ;
total_bill = 0.0 ;
row++ ;
}
gotoxy(4,row) ;
cout <<billno ;
}
flag = 1 ;
gotoxy(11,row) ;
cout <<dd <<"/" <<mm <<"/" <<yy ;
gotoxy(24,row) ;
cout <<code ;
gotoxy(32,row) ;
cout <<name ;
gotoxy(52,row) ;
cout <<cost ;
gotoxy(59,row) ;
cout <<price ;
gotoxy(67,row) ;
cout <<quantity ;
total = quantity * price ;
gotoxy(73,row) ;
cout <<total ;
total_bill = total_bill + total ;
if ( row >= 23 )
{
row = 5 ;
gotoxy(66,1) ;

cout <<"Page no. : " <<pageno ;


pageno++ ;
gotoxy(1,25) ;
cout <<"Press any key to continue..." ;
getche() ;
clrscr() ;
gotoxy(30,2) ;
cout <<"LIST OF BILLS" ;
gotoxy(3,4) ;
cout <<"Billno. Date Item Code Item name
Cost Price Qty Total" ;
gotoxy(3,5) ;
cout<<"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~" ;
}
prev_billno = billno ;
}
row++ ;
gotoxy(52,row) ;
cout <<"TOTAL BILL: Rs." <<total_bill <<"/=" ;
if ( !found )
{
gotoxy(5,10) ;
cout <<"\7Records not found" ;
}
gotoxy(66,1) ;
cout <<"Page no. : " <<pageno ;
gotoxy(1,25) ;
cout <<"Press any key to continue..." ;
getche() ;
file.close () ;
}

//****************************************************
******
// THIS FUNCTION IS THE MAIN FUNCTION CALLING THE
MAIN MENU
//****************************************************
******
void main(void)
{
clrscr() ;
menu m ;
textmode(BW80);
m.main_menu() ;
//close graph();
}

TESTING
In a software development project, errors can be injected at any stage during
development. There are different techniques for detecting and eliminating
errors that originate in that phase. However, no technique is perfect, and it is
expected that some of the errors of the earlier phases will finally manifest
themselves in the code. This is particularly true because in the earlier phases
and most of the verification techniques are manual because no executable
code exists. Ultimately, these remaining errors will be reflected in the code.
Hence, the code developed during the coding activity is likely to have some
requirement errors and design errors, in addition to errors introduced during
the coding activity. Behavior can be observed, testing is the phase where the
errors remaining from all the previous phases must be detected. Hence,
testing performs a very critical role for quality assurance and for ensuring
the reliability of software.
During testing, the program to be tested is executed with a set of test cases,
and the output of the program for the test cases is evaluated to determine if
the program is performing as expected. Due to its approach, dynamic testing
can only ascertain the presence of errors in the program; the exact nature of
the errors is not usually decided by testing. Testing forms the first step in
determining the errors in a program. Clearly, the success of testing in
revealing errors in programs depends critically on the test cases.
Testing a large system is a very complex activity, and like any complex
activity it has to be broken into smaller activities. Due to this, for a project,
incremental testing is generally performed, in which components and
subsystems of the system are tested separately before integrating them to
form the system for system testing. This form of testing, though necessary to
ensure quality for a large system, introduces new issues of how to select
components for testing and how to combine them to form subsystems and
systems.

Verification and Validation (V&V)


The objectives of verification, validity activities are to assess and improve
the quality of the work products generated during development and
modification of the software. Quality depends upon the various attributes
like correctness, completeness, consistency, reliability, usefulness, usability,
efficiency and conformance to standards.
The terms verification and validation are used synonymously. These are
defined as under: Verification: Are we building the product right?
Validation: Are we building the right product?
Verification activities include proving, testing, and reviews. Validation is the
process of evaluating software at the end of the software development to
ensure compliance with the software requirements. Testing is a common
method of validation. Clearly, for high reliability we need to perform both
activities. Together, they are often called V&V activities.
The major V&V activities for software development are inspection, reviews,
and testing (both static and dynamic). The V&V plan identifies the different
V&V tasks for the different phases and specifies how these tasks contribute
to the project V&V goals. The methods to be used for performing these
V&V activities, the responsibilities and milestones for each of these
activities, inputs and outputs for each V&V task, and criteria for evaluating
the outputs are also specified.
The two major V&V approaches are testing and inspections. Testing is an
activity that can be generally performed only on code. It is an important
activity and is discussed in detail in a later chapter. Inspection is a more
general activity that can be applied to any work product, including code.
Many of the V&V tasks are such that for them, an inspection type of activity
is the only possible way to perform the tasks (e.g. trace ability and document
evaluation). Due to this, inspections play a significant role in verification.

TEST REPORTS
Cause-effect graphing is a technique that aids in selecting combinations of
input conditions in a systematic way, such that the number of test cases does
not become unmanageably large. The technique starts with identifying

causes and effects of the system under testing. A cause is a distinct input
condition, and an effect is a distinct output condition. Each condition forms
a node in the cause-effect graph. The conditions should be stated such that
they can be set to either true or false. For example, an input condition can be
"file is empty," which can be set to true by having an empty input file, and
false by a nonempty file. After identifying the causes and effects, for each
effect we identify the causes that can produce that effect and how the
conditions have to be combined to make the effect true. Conditions are
combined using the Boolean operators "and," "or," and "not," which are
represented in the graph by &, I, and ""'. Then, for each effect, all
combinations of the causes that the effect depends on which will make the
effect true, are generated (the causes that the effect does not depend on are
essentially "don't care"). By doing this, we identify the combinations of
conditions that make different effects true. A test case is then generated for
each combination of conditions, which make some effect true.
Cause:
c1. Command is item available
c2. Command is item not available
c3. Customer purchasing item.

Effects:
el. Print "invalid command"
e2. Print "invalid item-number"
e3. Print item not available

Maintenance
After the installation phase is completed and the user staff is adjusted to the
changes created by the candidate system, evaluation and maintenance begin.
Like any system, there is an aging process that requires periodic
maintenance of hardware and software. If the new information is
inconsistent with the design specifications, then changes have to be made.
Hardware also requires periodic maintenance to keep in tune with design
specifications. The importance of maintenance is to continue to bring the
new system to standards.
User priorities, changes in organizational requirements, or environmental
factors also call for system enhancements.
TO contrast maintenance with enhancement, if a restaurant decided to
increase its service charges from $ 3.00 to $ 4.50 for a minimum balance of
# 300, it is maintenance. This change requires evaluation, program
modifications, and further testing.

Project Termination
A system project may be dropped at any time prior to implementation
although it becomes more difficult (and costly) when it goes past the design
phase. Generally projects are dropped if after a review process, it is learned
that:

Changing objectives or requirements of the user cannot be met by the


existing design.
Benefits realized from the candidate system do not justify commitment to
implementation.
There is a sudden change in the user's budget or an increase in design
costs beyond the estimate made during the feasibility study.
The project greatly exceeds the time and cost schedule.

In each case, a system project may be terminated at the user's request. In


contrast to project termination is new system failure.
There are many reasons a new system does not meet user requirements:

User requirements were not clearly defined or understood. The user was
not directly involved in the crucial phases of system development.
The analyst, programmer, or both were inexperienced.
The systems analyst (or the project team) had to do the work under the
stringent time constraints. Consequently, not enough thought went into
the feasibility study and system design.
User training was poor.
Existing hardware proved deficient to handle the new application.
The new system left users in other departments out of touch with
information that the old system had provided.
The new system was not user-friendly.
Users changed their requirements.
The user staff was hostile.

The list can be expanded to include many more causes. The important point
is that although advances in computer systems and software make life easier
for the analyst, the success of the system project depends on the experience,
creative ability, and knowledge of the analyst and the support from the user
staff. This suggests that the analyst be skilled in the state of the art (hardware
and software) as well as in dealing with people.

Scope of Future Application


This project can be used in the fast food restaurant after adding some more
useful modules in the project for which fast food are providing services.
Utmost care and back-up procedures must be established to ensure 100%
successful implementation of the computerized fast food management
system. In case of system failure, the organization should be in a position to
process the transaction with another organization or if the worst comes to the
worst, it should be in a position to complete it manually.

Scope of Improvement
Now a days fast food restaurants are providing many other facilities, this
project can also be improved with the improvement in the restaurant.
Utmost care and back-up procedures must be established to ensure 100%
successful implementation of the computerized banking system. In case of
system failure, the organization should be in a position to process the
transaction with another organization or if the worst comes to the worst, it
should be in a position to complete it manually.

CONCLUSION
This project is designed to meet the requirements of Fastfood Management.
It has been developed in C++, keeping in mind the specifications of the
system.
For designing the system we have used simple data flow diagrams.
Overall the project teaches us the essential skills like:

Using system analysis and design techniques like data flow diagram in
designing the system.
Understanding the database handling and query processing.

OPERATIONAL INSTRUCTION
FOR THE USER
1) If the computer is off, turn the power switch of the computer and
the printer, the System will check the RAM for defects, and also
looks at the connections to the Keyboard, disk drive etc, to see if
they are functional.
2) When the system is ready it will BOOT or load the operating
system into the memory from the hard disk.
3) Copy the floppy(i.e. A: Drive) on the hard disk(i.e. C: Drive).This
will copy all the required files from A: drive to C: drive.
4) Before the user exit from the Main Menu he/she can try all the
required options.
5) Exit from Main Menu with the selection of option EXIT in Main
Menu.
6) This project is a program written in TURBO C++ for Fastfood
Management System. Using this project user
maintain the record of the items in the resturant.

will be able to

INSTALLATION PROCEDURE
The following steps are used for installation of FASTFOOD
Management System application on the user site. The installation
procedure is given in steps:1) Create a Directory in the Hard Disk or C: Drive with the any name.
2) Insert the floppy disk in A: drive that contain the software files i.e.
EXE File, DAT File (Data base File), Header file & CPP files
3) Copy all files from A: Drive into the C: Drive into a specified
directory
4) Run the FASTFOOD.EXE File. This will lead to start the Bank
Management System software.
5) There is no need of Developing the Software like Turbo C++
because Exe will is self executable with name.
6) In order to Start the project or application immediately after
BOOTING make the directory entry in Autoexec.bat file and write
the name of fastfood.exe and save the file.

BIBLIOGRAPHY
1) The C++ COMPLETE of G.S. BALUJA of Khanna
Publications.
2) The C++ PROGRAM DESIGN of DIETEL & DIETEL.
3) The TURBO C++ of ROBERT LAFORE.
4) The C++ PROGRAM DESIGN & PROGRAMMING of
BALAGURUSWAMY.
5) Roger S. Pressman Software Engineering A Practioners
Approach.
6) Yashavant Kanetkar C PROJECT.
7) E.M. Awad System Analysis & Design.
8) V. RAJARAMAN Analysis & Design of Information
System.

You might also like