Develop a library information system that provides the following functionalities :
a) Add New Patron
b) Search Patron
c) Check Out Book
The patron ID is unique and is generated automatically by the system. Any patron can borrow at most three (3) books. The period of loan is two (2) weeks. Your program will retrieve the computer’s current date to be used as the date a book is borrowed and calculate the due date automatically. You can make the assumption that the library has only one copy of any book title. At least five (5) patrons’ data should be used to demonstrate the working of the system.
Sample Output
Library Information System
(Add New Patron)
------------------------------------------------------------------------------------------
Patron ID : LS0452
Name : Edward Johnson
Address : 3, Green Street, Petaling Jaya, Selangor
Tel. No : 03-12345678
Save record ? [y/n]
Library Information System
(Check Out Book)
------------------------------------------------------------------------------------------
Date : 21/01/2002
Serial Number : 005.133 HOR
Patron ID : LS0452
Save record ? [y/n]
Library Information System
(Search Patron)
------------------------------------------------------------------------------------------
Enter Patron ID : LS0452
Record found.
Patron ID : LS0452
Name : Edward Johnson
Address : 3, Green Street, Petaling Jaya, Selangor
Tel. No : 03-12345678
Item 1
-------
Serial Number : 005.133 HOR
Date Borrowed : 21/01/2002
Due Date : 03/02/2002
Item 2
-------
Serial Number : 205.54 GD
Date Borrowed : 24/01/2002
Due Date : 06/02/2002
a) Add New Patron
b) Search Patron
c) Check Out Book
The patron ID is unique and is generated automatically by the system. Any patron can borrow at most three (3) books. The period of loan is two (2) weeks. Your program will retrieve the computer’s current date to be used as the date a book is borrowed and calculate the due date automatically. You can make the assumption that the library has only one copy of any book title. At least five (5) patrons’ data should be used to demonstrate the working of the system.
Sample Output
Library Information System
(Add New Patron)
------------------------------------------------------------------------------------------
Patron ID : LS0452
Name : Edward Johnson
Address : 3, Green Street, Petaling Jaya, Selangor
Tel. No : 03-12345678
Save record ? [y/n]
Library Information System
(Check Out Book)
------------------------------------------------------------------------------------------
Date : 21/01/2002
Serial Number : 005.133 HOR
Patron ID : LS0452
Save record ? [y/n]
Library Information System
(Search Patron)
------------------------------------------------------------------------------------------
Enter Patron ID : LS0452
Record found.
Patron ID : LS0452
Name : Edward Johnson
Address : 3, Green Street, Petaling Jaya, Selangor
Tel. No : 03-12345678
Item 1
-------
Serial Number : 005.133 HOR
Date Borrowed : 21/01/2002
Due Date : 03/02/2002
Item 2
-------
Serial Number : 205.54 GD
Date Borrowed : 24/01/2002
Due Date : 06/02/2002
Comment