Prachi Banking Mgt. System

Download as rtf, pdf, or txt
Download as rtf, pdf, or txt
You are on page 1of 81

A

PROJECT REPORT
ON
“BANKING MANAGEMENT SYSTEM”
SUBMITTED TO
KURUKSHETRA UNIVERSITY, KURUKSHETRA
In the partial fulfillment of requirement
For the degree
B.Com-III rd Semester (Computer Application)
Session (2020-21)

UNDER SUPERVISION OF: SUBMITTED BY:

Ms. Shilpa Seth Prachii


Assistant Prof. B.Com. III Sem. (Comp. App.)
Dept. of Comp. Sc. & App. Class Roll No. 3248220006
Univ. Roll No…….
DEPARTMENT OF COMPUTER SCIENCE & APPLICATIONS
MUKAND LAL NATIONAL COLLEGE,
YAMUNA NAGAR- 135001
INDEX

Content PageNo.
 CERTIFICATE

 AKNOWLEDGEMENT

 PREFACE

 INTRODUCTION TO PROBLEM AREA

 OBJECTIVES OF THE PROJECT

 EXISTING SYSTEM

 PROPOSED SYSTEM

 HARDWARE AND SOFTWARE REQUIREMENTS

 SYSTEM ANALYSIS AND DESIGN

 OUTPUT

 ADVANTAGES OF THE PROJECT

 LIMITATIONS OF THE PROJECT

 FURTHER SCOPE

 CONCLUSION
 REFERENCE

CERTIFICATE
TO WHOM IT MAY CONCERN

Certified that M. Prachi D/o Mr.Mukesh Kumar a student of B.Com- 3th Semester (C.A.) ,

Roll No. 3248220006 of Department of Computer Science & App. , M.L.N. College,

Yamuna Nagar has completed the project entitled "BANKING MANAGEMENT

SYSTEM" which is candidate’s original work .

We wish her ever success in her life.

Ms. Priyanka Gandhi Dr. Neeti Daryal Dr. Rahul Khanna


Assistant Prof. H.O.D Principal,
Dept.of Comp.Sc. Dept. of Comp. Sc. M.L.N.College,
M.L.N. College M.L.N.College, Yamuna Nagar
Yamuna Nagar Yamuna Nagar
STUDENT DECLARAION
STUDENT DECLARAION
I am SURUCHI student of class B. Com(C.A.) Vth sem in Mukand Lal National
College, Yamuna Nagar roll no. 2366920023. I Hereby declare that the project report
entitled HOTEL MANAGEMENT SYSTEM is my individual work and not deposit or
submitted for an award of any Bachelor degree.

SURUCHI MAHENDRU
2366920023
B. Com (C.A.) V th sem.
SUPERVISION
CERTIFICATE
SUPERVISION CERTIFICATE

This is to certify that project report entitled “HOTEL MANAGEMENT SYSTEM” Special
reference to Department of Computer Application, Mukand Lal National College, Yamuna
Nagari, a piece of work carried out by Suruchi Mahendru, student of B.Com III rd year,
Mukand Lal National College, Kurukshetra university to university under my supervision.
He has worked independently on this project with best possible efforts.

Ms. Suruchi Mahendru


Department of Computer Application
Mukand Lal National College, Yamuna Nagar.
ACKNOWLWDGEMENT
ACKNOWLWDGEMENT
In the present world of competition there is a race of existence in which those are having will
to come forward succeed. Project is like a bridge between theoretical and practical working.
With the willing I joined the particular project. First of all, I would like to thank the supreme
power the Almighty God who is obviously the one has always guided me to work on the one
has always guided me to work on the right path of life. Without his grace this project could
not become a reality. Next to him are my parents, whom I am greatly indebted for me,
brought up with love and encouragement to this stage? I am feeling oblige in taking the
opportunity to sincerely thanks to Dr.P.K. Bajpai (Principal of Maharaja Agrasen
College) and special thanks to Mr. Randeep Kamboj (H.O.D. Dept of Computer Science
& Application) and my worthy teacher Miss Vaishali (Assistant professor in Computer
science and Application department). Moreover, I am highly obliged in taking the
opportunity to sincerely thanks to all the staff members of computer department for their
generous attitude and friendly behaviour. At last but not the least I am thankful to all my
teachers and friends who have been always helping and encouraging me though out the year.
I have no valuable words to express my thanks, but my heart is still full of the favours
received from every person.

Suruchi Mahendru
B.Com 5th Sem.(C.A.)
PREFACE
PREFACE
In ever widening modern world, the present system of education is facing new challenges. It
is well known fact that today is the age of computers. The major achievement of science and
technology. Now days everyone is realizing the importance of computer which is
achievement of modern age in fifth generation of computer.

In the modern era of science and technology as a powerful nation. India is still lagging
behind due to advancement in computer technologies. This problem can be overcome only
when the youth of India of the present generation give full co-operation in rising India as a
powerful nation by learning more and more computers.

So, realizing this fact and according to time demand when computers are necessary and
important achievement, I have chosen this vocational course from Kurukshetra University,
Kurukshetra.

The ability to do a project work is not merely the output of intelligence and hard work; it also
requires the patience and stability. While working on this project, apart from these qualities I
have developed the necessary communication skills and attributes, which are always required
in a professional field. It is through this phase of learning that an individual gain attitude to
work in a cooperative manner while working as a term member. Though the most part of the
work in his own efforts yet the person learn more by discussions and conclusion. Problems
are solved and more and more questions arise and with each and every solution there is a
gain in confidence.
ACKNOWLEDGEMENT

First of all I am sincerely thankful to the power on the earth GOD who gives me blessing for

the completion of my project report.

I feel obliged in taking the opportunity to thanks Dr. Shailesh Kapoor (Principal M.L.N.

College) for her kind cooperation.

My primary thanks go to Dr. Neeti Daryal (H.O.D, Comp. Sc. & Deptt.) & next to my

guide Ms. Palak (Lect. of Computer Science & Application) who poured over every inch

of the case study with pains taking attention to details & made a semi-infinite number of

helpful suggestions.

I am also grateful to my parents, my brother and teachers who gave me full support and their

precious time to me and my problem faced during my project work and guided me to make

this project into a successful one.

Prince Jagga
B.Com – 5th Semester (C.A.)
PREFACE
PREFACE

Today everybody is realizing the importance of computers. Computers are one of the useful

inventions of science and technology. They are revolutionizing each and every aspect of our

life. Use of Computers in business and commercial areas has become in today’s world.

Computers usage is growing leaps and bounds in business, industry, government and

institution of studies like school, college and universities. The rate at which demand is

growing, our country could not produce requisite expertise to match the demand.

This course is aimed at making student complete & self reliant programmers. We are

imparted all knowledge about structure & basis of computer at first stage. Thus a candidate is

exposed to this time environment.

Today, there is hardly any sphere of human activity which has not been covered by

computers.
The traditional manual system of banking system for customers was a difficult task and time

consuming also due to increase in technology computer has proved a boon to such

organizations.

Therefore, computerized banking system has become important and must.

INTRODUCTION TO PROBLEM

AREA
INTRODUCTION TO PROBLEM AREA

Computers have altered completely the structure of the businesses. Large volume of

accounting and record-keeping data can be manipulated, organized, stored, retrieved and

used for specific purpose. Financial projections are made with proper & greater care. As the

computer helps manager organize and manipulates financial data. In manufacturing industry,

computers direct production, guides machines and tools, controls quality, design parts and

monitor inventories.

If we handle the system manually, a large number of man powers are required. With

computerization system manpower may be saved. Time may also be saved.

Reducing the time factor for payment if money, computer will do the job accurately,

efficiently and in time up to date information may be obtained from computer any time.

The output generated by the computer will be in tabulated from which will be understood

more clearly. Neatly typed results will be taken hence making the reading easy. Multiple

copies can be generated at a time, thus saving the time.

In order to success any record it will only require to give a suitable command to the computer

and the desired record will either be displayed on the screen or printer.

A calendar is also a physical device (often paper). This is the most common usage of the

word. Other similar types of calendars can include computerized systems, which can be set to

remind the user of upcoming events and appointments.


A calendar can also mean a list of planned events, such as a court calendar.

This project “CALENDER SYSTEM” has been developed keeping in mind all the views,

which a user may look for. The project has been developed in such a way that it can quest

easily the user queries.

The system consists of a main menu in which the user has to press the arrows keys according

to the function he/she wants to perform. A user can choose any sorting option according to

the specification.

In an organization computerization is done for a particular problem which is hard-to-do for a

man. The computerization of problem is done on the basis of different factors:

 Difficulties in the manual process.

 More time and effort needed.

 If the job is tedious, then we have to select area for computerization.

Each organization has its own particulars and it is usually not advisable to graft the existing

design of one organization in to another. It is difficult task to carry out the system design.

The need for system development may arise from expansion of business, unsatisfactory,

labour machine utilize, shortening in delivery time by improvement in the information

system, excessive over time etc.


Publisher 2000 makes it easy to create a calendar with one or more months in the same

publication or a calendar for the entire year. You can create full-sized or pocket-sized

customized calendars. In this lesson, you will use the Calendar Wizard to create an April-

May calendar and customize it with text and pictures for your unit on marine mammals.
INTRODUCTION
TO
PROJECT
INTRODUCTION TO PROJECT
A bank is an organization which accepts deposits, withdrawn by cheque and makes loans and
advances interests for the purpose of earning profit. The BANKING has become the
undercurrent of modern economic development.

Organization Study
Various types of activities are undertaken in this organization. The following are undertaken
in saving account section of the bank.
1. Opening of account
2. Deposits in the account
3. withdrawals
4. Interest calculation
5. Closing the account
But in current account section withdrawals are not used, rather money is withdrawn using
cheques. Before giving the details description of each activity mentioned above firstly we
have to know what an account provide.
Account provides an ideal opportunity to save money for future contingency. Besides earning
interest, the account holder is also relieved from the strain of holding idle cash at home and
yet convenient type of account for deposit / withdrawals / payment of funds to individuals ,
pensioners , housewives , students etc.
THE FUNCTIONS OF BANKING ARE AS FOLLOWS:

OPEN AN ACCOUNT

 An individuals who is more than 18 years of age and capable of entering into a contract

can open an account.

 New account is opened with an introduction by an existing customer.

 Two passport size photographs are to be given at the time of opening an account with

Cheque book facility.

 Persons authorized to operate upon the account are also required to give two passport size

photographs.

 Account can be operated any number of times. There is no upper limit for maintaining

balance. However, a minimum balance is required to be maintained. Separate numbers

are allotted to each account and customer should always quote this no. While dealing

with the branch.


2. DEPOSIT

 Amount can be deposited subject to be minimum of Re 1. /- by any person either in cash

or by cheque/drafts etc., through pay-in-slip.

 It must be distinctly understood that though entries may have been made to the credit of

an account against (clearing) cheques/drafts etc., in the pass book, such amounts are not

available for drawings till their realization.

 For the purpose of repaid posting “Pay-in-Slip system of Ledger posting” in adopter

under this system, posting of transactions in personal ledgers is made directly from slips

rather than from subsidiary books or journal. A slip is also called a voucher. The main

slips used in a bank are Pay-in-slips. These are filled up by the clients of the bank

themselves or by bank staff or the printed forms of the bank:-

 for making deposit with a bank, the customer has to fill up “Pay-in-slip” form and

submit into the receiving cashier of the bank along with cash. The form of “Pay-in-slip”

has two parts. The left hand side portion of it is called counterfoil”. It is returned by the

receiving cashier after counting the cash. The counterfoil bears signature of receiving

cashier and it is duly stamped with rubber stamps of the bank. It serves as an

acknowledgement of deposits made by the customers with the bank. Now the right hand

side part of the slip remains with the bank which serves as voucher for bank. the

receiving cashier makes entry in cash book and then passes on this slip to the “personal

Accounts ledger keeper” for posting in the ledger accounts of the customer.
3. WITHDRAWLS

a. Drawings from the account can be made by cheques or withdrawals slip supplied

by the branch.

b. The account holder can make payments by means of cheques to third parties.

c.Customer who wishes to withdraw money by means of withdrawal slip must present

pass book personally and get a withdrawal slip against acknowledgment.

In case of illiterate persons, left thumb impression is obtained in the presence

of illiterate person, knows to the branching witness of the same.

d. A person can’t withdraw a lesser sum than Re. 1/- except at the time of closing

account.

e. Withdrawal slip can not be made payable to third parties and hence not negotiable.

1)With drawl of large amount from the account is allowed against advance notice. The

Bank may, however, allow such withdrawal without insisting for prior notice at

its sole discretion.

2)The following cases of withdrawals are not honoured:

(a) Stale and post-dated cheques/withdrawals slips.

(b) Cheques/withdrawals slips drawn for amounts in excess of balance at credit.

(c) Alteration in cheques/withdrawal slip not authenticated by drawer’s signature

in full.

(d). For withdrawing an accounts from the bank, the customers has to fill up

‘cheque’ or ‘withdrawal’ form and submit it to ‘Personal Accounts Ledger keeper’

who gives a token to the customer. Now ledger keeper checks the slip for

signature of customer and for adequacy of amount in his ledger accounts. He also
makes posting of withdrawal in ledger account of customer. Now the slip

(Voucher) is passed on to ‘Paying cashier’ of the bank who makes Payment to

customer after receiving the token from him.

4.INTEREST CALCULATION

Bank also pays interest on saving deposits account on half yearly bases in month of

June and December at the rates specified by RESERVE BANK OF INDIA. The

interest is calculated on monthly product bases. For the period of December - May in

the month of June & for June-November in the month of December. The monthly

predicts are taken as the minimum balance on any day during the period of 10th to the

last date of the month. The monthly products for six month are added one month’s

interest at the prescribed rates is paid on this added amount. Interest is also paid in the

case of closing of account for the period left after payment of last interest.

5.CLOSING OF ACCOUNT

The account holder can ask for closing of account ay any time for which he requests

in writing and either issues a cheque or withdrawal order form for the balance

outstanding in account including up to date interest or instructs the Bank to depose off

the balance in any other manner. E.g. issue of demand draft/pay order, transfer of

balance outstanding in the account is posted in the ledger and the remarks are given in

the ledger sheet.


GENERAL

 In the event of death of customer, the amount standing to the credit of account becomes

payable on demand to the Nominee/legal representative of the deceased on production of

satisfactory proof. In the case of joint account, on the death of one account holder, the

balance is payable to the survivor/legal heirs/nominee depending on the terms of the

repayment.

 The bank reserves the right to refuse opening of an account. The bank has the right to

close any desirable account at its discretion by giving reasonable notice.


EXISTING SYSTEM
EXISTING SYSTEM

A person who is working manually has to remember all the activities. The work done by
manually is not much fast and very much stationary is required for entering in accounts. All
the transaction has to remember. Alteration in always is very difficult. There are many
disadvantages relating to this manual system.

In the manual system records are kept in the following books:


1. PASS BOOK GIVEN TO THE PERSON.
2. CARD
3. LEDGER
4. REGISTERS

Disadvantages of the manual system

More Stationary is required: - In manual system there is more stationary is required for
preparing the accounts, which is extra burden on bank.

Wasting of time: - All transaction of the bank is rewarded on the basis of slips. So this system
waste more time customers have to wait for long time in queues
.
Modification is difficult: - In manual system the work is done by manually So there is a
chances of mistakes So modification is difficult.

Maintains is difficult: - As the number of daily transactions is quite large in a bank, it


becomes very difficult and experiences to keep a date wise records of such a large number of
slips by manual.

Immediate access: - Immediate access is not done.


PROPOSED SYSTEM
PROPOSED SYSTEM

The activities involved in computerized system are very much similar that of the manual

system. But as compared to the services provide by manual system the computerized system

is very fast. There is no paper work so there should be no bulky or irritating registers. The

changes can easily be done in the customer record.

This system has no disadvantages which the manual system. In this system quick result is

given by computer, So that less time is consumer by this system other than manual. Some

advantages related to computerized System.


ADVANTAGES OF COMPUTERIZED SYSTEM

Saving of Time: - The daily activities are performed very quickly as compared to manual

system. It requires less time customer has not to wait for long time in queues.

No need for Subsidiary books: - In this system all the entries are entered with the help of

basis slips. Therefore, there is no need for keeping subsidiary books.

Up-to-date Accounts: - Computerized system helps in keeping the customers accounts

always up-to-date. Every transaction is entered in the concerned account as soon as it takes

place.

Modification is easy: - In computerized system we can modify accounts easily. So in this

system modification is quite easy.

Quick Service: - In computerized system the services provide by the computer is so much

fast. So we can say that it provides quick services to its customers.


SYSTEM ANLYSIS
&
DESIGN
SYSTEM ANALYSIS

A. Conception

Management of the Bank feels that the manual system is slow and this irritates the

incoming customers. Moreover, the inquiry should be immediate rather than browsing

the pages of the register. He also feels that in the modern world nobody will like to

wait long for the bill and he himself wish to get the statement of the day’s transactions

in a structured form which should be error free and timely.

Management also feels that by taking an interest in this connection, he will add to the

repute of the bank and allure the customers, so he decided to get the Banking system.

B. Feasibility study

An initial investigation culminates in a proposal that determines, whether an

alternative system is feasible. A proposal summarizing the thinking of the analyst is

presented to the user for review, when approved it initializes a feasibility study that

describes and valuates candidate system and provides for the selection of the best

system and meets the system’s requirement.

The three keys considerations in the feasibility study analysis are:-

1. Economic feasibility

2. Technical feasibility

3. Operational feasibility.
1. Economic feasibility

Economic analysis is the most frequently used method for evaluation of the
effectiveness of a candidate system. The proposed system is economically feasible;
because the benefits and the saving that are expected from the candidate system
outweighs the cost incurred. In this case we are getting the tangible benefits in terms
of low cost of maintenance of the data, less redundancy of the data and getting quick
results. One time cost is purchasing a computer and trained operator.

2. Technical feasibility

Technical feasibility centers on the existing computer system (Hardware, software)


and is technically viable, because this can turn on simple pc having database
package like access.

3. Operational feasibility

People are inherently resistant to change; computers have been known to facilitate
change. An estimate is made of how strong a reaction the user is likely to have
towards the development of a computerized system. By implementing this project,
there is not going to be major change in the main power. A little of training is
required, but its proposed ease of usability would not darer the to avoid it. So we
see that the system is technically, economically and operationally feasible.
SYSTEM DESIGN

Designing anything is it physical, arithmetic or social, it is creative process. System

design is a logical approach, which implies Systematic move towards the end project, each

step being the result of decision, based upon the previous step. In fact practically

efficiency, least cost, flexibility and security are the main objectives, which should keep in

mind at the time of design of the system.

For accurate system design, one should know the exact nature of output needed and it’s

exact layout needed, specification for input is made and then logic is developed and layout

of files to be used is determined.

There are three phases of the database design.

 File design

 Input design

 Output design

FILE DESIGN:

This is the most important part of the system design. System design is based
on the system analysis while designing the files care have been taken to the group of
data items in such a manner so as to avoid duplication the file design begins with the
name of database file, the sure of the file, the frequency of getting input to that
particular file.
INPUT DESIGN:

Great care should be taken in designing the input so that there should be no conflicts in the
output

OUTPUT DESIGN:

The major concern of the user in system is always with the output, therefore the output
design must be designed intelligible and decision Impelling. Once output report formats and
contents have been fixed the system analyst can work backward and draw the inputs, going
further back, the system analyst would evolve suitable procedures and design the forms to
captures the input data organization.
Main Menu

1. New Account

2. List of Account

3. Report for a particular Account

4. Daily transaction

5. Edit Account

6. Exit

New Account: - This option is used to open a account.

List of Account: - This option shows the details of all existing account.

Report for a particular Account:- This option is used to show a particular account.

Daily Transaction: - This option has two choices.

1 . To deposit money in a particular account.

2. To withdraw money in a particular account.

Edit Account: - It has also two options.

1 . To modify a particular account.

2. To choice/delete a particular account.

Exit: - To exit from the program.

STRUCTURE: - Group variables in a single record.


Struct cus

{
Char na [30], ad [60], vn [30]

//na for name


//ad for address
//vn for verifier name
float in // for initial deposit
ins s, m1, m2, m3

};

Graphics

Initgraph (&gd, &gm,); .This function is used to initial graphics drivers

Close graph: - shut down the graphics system.

Input output stream

File *fp, *ft

File control structure for system.

Date and time function

getdate() ; to initializes current date.

gettime() ; to initializes current time.


OUTPUT
OUTPUTS

DATE: 10-8-2019
TIME: 01:14:30

+------------------------------------------------+
¦ BAN KI NG ¦
¦ +--------------------------------------------+ ¦
¦¦ 1.New Account ¦¦
¦¦ ¦¦
¦¦ 2.List of Account ¦¦
¦¦ ¦¦
¦¦ 3.Report for A Particular Account ¦ ¦
¦¦ ¦¦
¦¦ 4.Daily Transaction ¦¦
¦¦ ¦¦
¦¦ 5.Edit Account ¦¦
¦¦ ¦¦
¦¦ 0. Exit ¦¦
¦¦ ¦¦
¦¦ ¦¦
¦ +--------------------------------------------+ ¦
¦ YOUR CHOICE ¦
+------------------------------------------------+
***************************************************
OPEN NEW ACCOUNT
***************************************************
Please Enter Your Data
***************************************************
Your Account No. is 3
***************************************************
NAME : Amit Joshi

ADDRESS: Kurukshetra

NAME OF VERIFIER: sunny

INTIAL DEPOSIT : 2000


Do you want save it: (y/n): y
*********************************************

Do You Want To Add More Record: n


Date: 10-8-2019
TIME: 22:4:37
*********************************************
ACCNO# NAME ADDRESS VERFIER NAME INITIAL DEPO.
*********************************************
1 varun Yamuna Nagar karan 5000.000000
2 abhishek chhachhrauli nishu 4000.000000
3 Simran chandigarh sunny 2000.000000
***************************************************
Total Balance in Bank 11000.00
***************************************************

Press any key to continue......


Date: 10-8-2019
Time: 22:4:37
**********************************************
Enter your account no. 4
**********************************************
ACCNO# NAME ADDRESS VERFIER NAME INITIAL DEPO.
**************************************************
3 Simran Chandigarh sunny 2000.000000
**************************************************
Date of Account Modification: 12-02-2007
**************************************************
Press any key to continue......
Date: 10-8-2019
Time: 22:4:37
*********************************************
Enter your account no. 3
**********************************************
Name: Simran
Last Balance: 2000.000000
Enter your Choice D/W: d

**************************************************
Enter deposit: 500
***************************************************
Now Balance: 2500.000000
*************************************************
Press any key to continue.......
Date: 10-8-2019
Time: 22:4:37
*********************************************
Enter your account no. 3
**********************************************
Name: Simran
Last Balance: 2500.000000
Enter your Choice D/W: w

**************************************************
Enter Withdraw: 1000
**************************************************
Now Balance: 1500.000000
*************************************************
Press any key to continue.......
DATE: 10-8-2019
TIME: 05:14:37

+------------------------------------------------+
¦ EDIT ACCOUNT ¦
¦ +--------------------------------------------+ ¦
¦¦ ¦¦
¦¦ ¦¦
¦¦ ¦¦
¦¦ 1. Modify Account ¦¦
¦¦ ¦¦
¦¦ ¦¦
¦¦ ¦¦
¦¦ 2. Close Account ¦¦
¦¦ ¦¦
¦¦ ¦¦
¦¦ ¦¦
¦¦ 0. Exit ¦¦
¦¦ ¦¦
¦ +--------------------------------------------+ ¦
¦ Enter Your Choice ¦
+------------------------------------------------+
**************************************************
Enter the serial no. of employee whose record is to be modified

Account No.1

Name: varun
Add: Yamuna Nagar
Verifier name: karan
Initial Amount: 5000.000000
********************************************
Do you want to modify name (y/n) y

Enter Name: akash

*********************************************
Do you want to modify address (y/n) y

Enter Address: Delhi


Do you want to modify another record also?
*********************************************
Enter the Account no. Of customer to be deleted

Enter Account No.: 2

********************************************
Account Holder's Name: amit joshi
*************************************************
If you are sure than please reenter this name: amit joshi

*************************************************
Do you want to delete more record (y/n) y
LIMITATIONS
LIMITATIONS

The main limitation of this project is that:-

1. This project is not password protected i.e. any user can access any

record from this project.

2. The project reduces paper work.

3. I have not provided any facility of menu bar.


CONCLUSION
CONCLUSION

Computer is today’s necessary of life. It has become part of our daily life as in every field

like in bank also. It gives great benefit to this field (Bank). Those banks who has been

computerized is much better than others . It saves customers time as well as users time. It

“return” customer also. Modification and Clarification is very easy by computer. We can

check daily transaction. We can add new record easily so we can say it’s good for banks and

country’s national growth.


REFERENCES
BIBLIOGRAPHY

 Let us c Yashavant Kanetkar

 Data Structure in c Robert L.Kruse

Bruce P.Leung

Clovis L.Tondo

 Web references www.funducode.com http://www.funducode.com

www.vivekpatel.cjb.net http://www.vivekpatel.cjb.net

www.codeproject.com <http://www.codeproject.com>
CODING

//PROJECT FOR BANKING WORK

//HEADER FILES INCLUDES

#include<stdio.h>

#include<conio.h>

#include<dos.h>

#include<graphics.h>

struct cus

//STRUCTURE FOR A CUSTOMER'S ACCOUNT

char na[30], ad[60], vn[30];

float in;

int s, m1, m2, m3;

};

Void box(int x1,int y1, int x2, int y2);

main ()

{ //M1 (M1 BRACKET FOR MAIN FUNCTION)


int gd=0,gm;

struct cus e;

//DECLARATION OF DIFF DATA TYPES & OTHERS

int d1, d2, d3,a;

unsigned int t1,t2,t3;

//STRUCTURE FOR TIME

struct time tt;

//STRUCTURE FOR DATE

struct date d;

//FILE POINTER

FILE *fp,*ft;

long int sz;

int i,no,t[100],j=0;

float to=0;

char ch,g[100],c,choice;

float w;

//INITIALIZE GRAPHICS FOR REPRESENTATION

initgraph(&gd,&gm," ");
sz=sizeof(e);

cleardevice();

//DESIGNING OF FIRSTPAGE

settextjustify(CENTER_TEXT,CENTER_TEXT);

setbkcolor(4);

settextstyle(1,0,8);

outtextxy(320,100,"WELCOME");

settextstyle(3,0,15);

setcolor(14);

outtextxy(320,200,"BANKING");

settextstyle(1,0,8);

outtextxy(320,300,"PROJECT");

settextstyle(1,0,5);

setcolor(15);

outtextxy(320,400,"Press Any Key to continue ...");

getch();

//CLOSE GRAPHICS

closegraph();

e.s=0;
//FUNCTION FOR CARRING TIME

gettime(&tt);

t1=tt.ti_min;

t2=tt.ti_hour;

t3=tt.ti_sec;

//FUNCTION FOR CARRYING DATE

getdate(&d);

d1=d.da_day;

d2=d.da_mon;

d3=d.da_year;

while(1)

//OUTPUT FOR MAIN MENU

{ //W1

clrscr();

gotoxy(30,1);

cprintf("DATE: %d-%d-%d \n",d1,d2,d3);

gotoxy(30,2);

cprintf("TIME: %d:%d:%d ",t1,t2,t3);

textcolor(4);

//REPRESENTATION OF MAINMENU BOXES THROUGH BOX FUNCTION


box(20, 6, 65, 20);

box(18, 4, 67, 22);

textcolor(1);

gotoxy(36, 5);

textbackground(4);

cprintf("\bB A N K I N G");

textbackground(0);

textcolor(7);

gotoxy(30,7);

cprintf("1.New Account");

gotoxy(30,9);

cprintf("2.List of Account");

gotoxy(30,11);

cprintf("3.Report For A Particular Account");

gotoxy(30,13);

cprintf("4.Daily Transaction");

gotoxy(30,15);

cprintf("5.Edit Account");

gotoxy(30,17);

cprintf("0. Exit");

gotoxy(30,19);
cprintf("\n\nYOUR CHOICE ");

scanf("%d",&i);

fp=fopen("p.dat","rb+");

if (fp==NULL)

fp=fopen("p.dat","wb+");

if (fp==NULL)

puts("cannot open file ");

exit(1);

//MAIN CASE STATEMENT FOR DIFF PURPOSES IN PROJECT

switch(i)

{ //S1

case 1:

//CASE FOR CUSTOMER'S ACCOUNT NEW ENTRY

clrscr();

ch='y';

fflush(stdin);
while (ch=='y'|| ch=='Y')

clrscr();

rewind(fp);

//SET THE CURSOR AT LAST ENTRY

if(fread(&e,sz,1,fp)==0)

printf("\n***************************************************");

printf( "\n\t\t\tOPEN NEW ACCOUNT");

printf("\n***************************************************");

printf("\nPlease Enter Your Data");

printf("\n***************************************************");

printf("\nYour Account No. is :1");

printf("\n***************************************************");

else

fseek(fp,-sz,SEEK_END);
//STATEMENT FOR CARRING AUTOMATICALLY ACCOUNTNO.

while(fread(&e,sz,1,fp)==1)

printf("\n***************************************************");

printf( "\n\t\t\tOPEN NEW ACCOUNT");

printf("\n***************************************************");

printf("\nPlease Enter Your Data");

printf("\n***************************************************");

printf("\nYour Account No. is %d",(e.s+1));

printf("\n***************************************************");

//SET THE CURSOR AT END

fseek(fp,0,SEEK_END);

e.s+=1;

//SET DATE OF ACCOUNT MODIFICATION

e.m1=d1;

e.m2=d2;

e.m3=d3;
//ENTRY OF ACCOUNTS

puts("\n NAME : ");

puts("\n\n ADDRESS : ");

puts("\n\n NAME OF VERIFIER : ");

puts("\n\n INTIAL DEPOSIT : ");

gotoxy(27,0);

cprintf("\n*********************************************");

gotoxy(18,9);

cscanf("%s",e.na);

gotoxy(18,12);

cscanf("%s",e.ad);

gotoxy(25,15);

cscanf("%s",e.vn);

gotoxy(25,18);

cscanf("%f",&e.in);

if (e.in<0)

printf("INVALID ENTRY");

printf("\nYOU CANNOT OPEN YOUR ACCOUNT WITH -VE INTIAL

AMOUNT");

else

{
printf("\nDo you want save it: (y/n): ");

fflush(stdin);

scanf("%c",&choice);

if ((choice=='y') || (choice=='Y'))

fwrite(&e,sz,1,fp);

printf("\n\n\nDo You Want To Add More Record ");

fflush(stdin);

scanf("%c",&ch);

printf("Press Enter Key To Continue ");

getch();

clrscr();

fclose(fp);

break;

case 2:

//CASE FOR SHOW ALL CUSTOMER'S ACCOUNT

rewind(fp);

clrscr();

gotoxy(30,2);

cprintf("Date: %d-%d-%d",d1,d2,d3);

gotoxy(30,3);
cprintf("TIME: %d:%d:%d",t1,t2,t3);

printf("\n*********************************************");

printf("\nACCNO# \t NAME \t ADDRESS \t VERFIER NAME \t

INITIAL DEPO.");

printf("\n*********************************************");

to=0;

//READING ACCOUNTS FROM P.DAT FILE

while(fread(&e,sz,1,fp)==1)

printf("\n%4d",e.s);

printf("%10s %14s %18s ",e.na,e.ad,e.vn);

printf("%22f",e.in);

fflush(stdin);

t[j]=e.in;

to=to+t[j];

j=j+1;

if (e.s%19==0)

printf("\nPress any key to continue .......");

getch();

printf("\n***************************************************");
printf("\nTotal Balance In Bank %0.2f", to);

printf("\n***************************************************");

printf("\n\nPress any key to continue......");

getch();

clrscr();

fclose(fp);

break;

case 3:

//CASE FOR SHOW A PARTICULAR ACCOUNT

clrscr();

printf("\nDate: %d-%d-%d",d1,d2,d3);

printf("\nTime: %d:%d:%d",t1,t2,t3);

printf("\n**********************************************");

printf("\nEnter your account no.");

printf("\n**********************************************");

gotoxy(25,5);

scanf("%d",&no);

printf("\n ACCNO#\t NAME \t ADDRESS \t VERFIER NAME \t

INITIAL DEPO.");

rewind(fp);

while(fread(&e,sz,1,fp)==1)
{

//CONTROL FOR READING A PARTICULAR ACCOUNT

if(no==e.s)

fflush(stdin);

printf("\n**************************************************");

printf("\n%4d",e.s);

printf("%10s %14s %18s ",e.na,e.ad,e.vn);

printf("%22f",e.in);

printf("\n**************************************************");

printf("\nDate of Account Modification: %d-%d-

%d",e.m1,e.m2,e.m3);

printf("\n**************************************************");

break;

printf("\nPress any key to continue ......");

getch();

clrscr();
fclose(fp);

break;

case 4:

//CASE FOR DAILY TRANSACTION

clrscr();

printf("\nDate: %d-%d-%d",d1,d2,d3);

printf("\nTime: %d:%d:%d",t1,t2,t3);

printf("\n*********************************************");

printf("\nEnter your account no.");

printf("\n**********************************************");

gotoxy(25,5);

scanf("%d",&no);

rewind(fp);

while(fread(&e,sz,1,fp)==1)

if(no==e.s)

fflush(stdin);

printf("\nName : %s",e.na);

printf("\nLast Balance: %f",e.in);

printf("\nEnter your Choice D/W: ");


scanf("%c",&c);

if(c=='d'|| c=='D')

//CONDITION FOR DEPOSIT

printf("\n**************************************************");

printf("\nEnter deposit: ");

printf("\n***************************************************");

gotoxy(15,12);

scanf("%f",&w);

e.in=e.in+w;

else if(c=='w'|| c=='W')

//CONDITION FOR WITHDRAW

printf("\n**************************************************");

printf("\nEnter Withdraw: ");

printf("\n**************************************************");

gotoxy(17,12);

scanf("%f",&w);
e.in=e.in-w;

fseek(fp,-sz,SEEK_CUR);

fwrite(&e,sz,1,fp);

printf("\nNow Balance: %f",e.in);

printf("\n*************************************************");

printf("\nPress any key to continue .......");

getch();

clrscr();

fclose(fp);

break;

case 5:

//CASE FOR EDITING ACCOUNT

clrscr();

//MENU FOR EDITING ACCOUNT

gotoxy(30,1);

cprintf("DATE: %d-%d-%d \n",d1,d2,d3);

gotoxy(30,2);
cprintf("TIME: %d:%d:%d ",t1,t2,t3);

textcolor(4);

box(20, 6, 65, 20);

box(18, 4, 67, 22);

textcolor(1);

gotoxy(36, 5);

textbackground(4);

cprintf("\bEDIT ACCOUNT");

textbackground(0);

textcolor(7);

gotoxy(30,10);

printf("1. Modify Account");

gotoxy(30,14);

printf("2. Close Account");

gotoxy(30,18);

printf("0. Exit");

gotoxy(30,20);

cprintf("\nEnter Your Choice");

scanf("%d",&a);

if(a==1)

//CONDITION FOR MODIFY ACCOUNT


{

char x,x2;

ch='y';

while (ch=='y'|| ch=='Y')

clrscr();

printf("\n**************************************************");

printf("\n Enter the serial no. of employee whose record is to be modified ");

gotoxy(10,5);

cprintf("Account No.");

scanf("%d",&no);

rewind(fp);

while (fread(&e,sz,1,fp)==1)

if(e.s==no)

printf("\nName: %s",e.na);

printf("\nAdd: %s",e.ad);

printf("\nVerifier name: %s",e.vn);

printf("\nInitial Amount: %f",e.in);

printf("\n********************************************");
printf("\nDo you want to modify name (y/n) ");

fflush(stdin);

scanf("%c",&x);

if(x=='y'||x=='Y')

printf("\nEnter Name : ");

scanf("%s",e.na);

printf("\n*********************************************");

printf("\nDo you want to modify address (y/n) ");

fflush(stdin);

scanf("%c",&x2);

if(x2=='y'||x2=='Y')

printf("\nEnter Address : ");

cscanf("%s",e.ad);

fseek(fp,-sz,SEEK_CUR);

fwrite(&e,sz,1,fp);

printf("\n*************************************************");
printf("Do you want to modify another record also ");

fflush(stdin);

scanf("%c",&ch);

printf("\nPress any key to continue......");

fflush(stdin);

getch();

clrscr();

fclose(fp);

break;

else if(a==2)

//CONDITION FOR DELETING ACCOUNT

ch='y';

while (ch=='y'|| ch=='Y')

clrscr();

printf("\n*********************************************");

printf("\nEnter the Account no. of customer to be deleted ");

gotoxy(10,5);

cprintf("Enter Account No.: ");


scanf("%d",&no );

printf("\n********************************************");

rewind(fp);

while(fread(&e,sz,1,fp)==1)

if(e.s==no)

gotoxy(10,8);

cprintf("Account Holder's Name:%s",e.na);

printf("\n*************************************************");

printf("\n If you are sure than please Reenter this name: ");

scanf("%s",g);

//CREATE A TEMP FILE

ft=fopen("m.dat","wb+");

rewind(fp);

while (fread(&e,sz,1,fp)==1)

if (strcmp(g,e.na)!=0)

fwrite(&e,sz,1,ft);

}
fclose(fp);

fclose(ft);

//REMOVE FIRST FILE &RENAME TEMP FILE AS MAIN FILE

remove("p.dat");

rename("m.dat","p.dat");

fp=fopen("p.dat","rb+");

printf("\n*************************************************");

printf("\nDo you want to delete more record (y/n) ");

fflush(stdin);

scanf("%c",&ch);

printf("\n************************************************");

printf("\nPress any key to continue..... ");

getch();

clrscr();

fclose(fp);

break;

else if(a==0)

clrscr();

break;
}

else

if (a!=1 && a!=2 && a!=0)

clrscr();

printf("\n*************************************************");

gotoxy(35,13);

cprintf("INVALID CHOICE");

getch();

break;

case 0:

//CASE FOR EXIT

fclose(fp);

exit();

default:

clrscr();

printf("\n**************************************************");

gotoxy(30,12.5);

cprintf("INVALID CHOICE");

getch();
} //S1 CLOSE

} //W1 CLOSE

} //M1 CLOSE

void box(int x1,int y1,int x2,int y2)

//FUNCTION DEFINATION FOR BOXES IN MAIN MENU

int col,row;

for(col=x1;col<x2;col++)

gotoxy(col,y1);

cprintf("%c",196);

gotoxy(col,y2);

cprintf("%c",196);

for(row=y1;row<y2;row++)

gotoxy(x1,row);

cprintf("%c",179);

gotoxy(x2,row);
cprintf("%c",179);

gotoxy(x1,y1);

cprintf("%c",218);

gotoxy(x1,y2);

cprintf("%c",192);

gotoxy(x2,y1);

cprintf("%c",191);

gotoxy(x2,y2);

cprintf("%c",217);

You might also like