Click here to Skip to main content
15,889,808 members
Please Sign up or sign in to vote.
1.00/5 (5 votes)
See more:
How to write the program used in libraries to monitor books borrowed and returned?
Posted
Updated 4-May-11 20:22pm
v2
Comments
Sandeep Mewara 5-May-11 2:14am    
No effort and lazy.

:doh:

It does not work like this here. I am sorry but there is no quick question here. This clearly sounds like your college project/assignment, you should put some effort.

We expect you to put some time in trying the issue that you are facing and then some time in formulating the question while posting here. I see both missing.

Here is what is expected by enquirers:
1. TRY first what you want to do!
2. Formulate what was done by you that looks like an issue/not working.

Try them and tell if you face issues.
Members will be more than happy to help like this.
 
Share this answer
 
As with your other question, google for RFID.
 
Share this answer
 
First of all you should think a little bit on the problem, make a requirement list... once you've prepared that start dividing the steps to get the job done...

Surely you'll need to ask for some data to the user... get familiar on how to do that cin and cout...
Then you'll have to store data... As a database has not been mentioned in any place... I guess this is a low level exercise... so you should think on arrays or linked lists.

This should be enough for you to start working...




From now on you will find extra spoilers...

Do you have a specific number of books?

If you would say that there are a specific number of books and shelves...

I would go for an array with some dimensions:

Spaces[MaxBooksNumberAllowed].

Each array position should be a structure with the fields you would need:

1. Book name.
2. State of the book. (1 is in the shelf, 0 is out).
3. shelf.
4. position in the shelf.
...

Then you should ask the operator of the program for an action:

1. Do you want to search for a book?
2. Do you want to insert a book?
3. Do you want to take a book?

then it is as easy as search for the book and act as deserved (removing it), insert a book (ask for the position or search for an empty slot and put it there)...

Good luck!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900