This module provides an interactive interface to the user
Module name | Description |
---|---|
book |
functions to manage a library system, including book management,tracking the issue and return of books, and updating book statuses |
import other dependencies based on the language chosen
Function name | Description |
---|---|
main() |
A user interface |
add_book() |
Adds a new book to the library |
find_book(name) |
Finds a book by its title |
list_books() |
Gets the list of all books in the library |
issue_book(name) |
Issues a book and updates its status to “Yes” |
return_book(name) |
Returns a book and updates its status to “No” |
Input:
Process:
add_book
, list_books
, issue_book
, return_book
).Output:
Input:
Process:
Book
object with the provided details.add_book
method of the Book
object to add the book to the library.Output:
Input:
Process:
Book
object with sample data.get_all_books
method of the Book
object to retrieve all books.Output:
Input:
Process:
list_books
function to get the list of all books and store into df.Book
object using the details of the found book.issue_book
method of the Book
object to update the issued status to “Yes”.Output:
Input:
Process:
list_books
function to get the list of all books and store into df.Book
object using the details of the found book.return_book
method of the Book
object to update the issued status to “No”.Output:
This format clearly outlines the inputs, processes, and outputs for each function, making it easier to understand and implement. If you need further assistance, feel free to ask!