LibraryManagementJavaProject_With_Statement
LibraryManagementJavaProject_With_Statement
Problem Statement:
Design and develop a console-based Java application named "Library Book Management
System" that simulates basic book management operations in a library. The system should
allow users to:
1. Add new book details including title, author, and publication year.
2. View all the books currently available in the system.
3. Search for books by matching keywords in the title or author name.
4. Delete a book from the system using its title.
5. Exit the application safely.
The system must be menu-driven and should provide appropriate prompts for user input.
The application should use core Java features such as:
Objective:
Build a functional and user-friendly system that demonstrates object-oriented
programming and data handling using basic Java.
Project Overview
This is a basic Java console-based project named 'Library Book Management System'.
The system allows users to perform the following operations:
The project uses core Java concepts like classes, objects, ArrayLists, Scanner for
input, and conditional logic.
Book.java
Library Book Management System - Java Project
Library.java
import java.util.ArrayList;
import java.util.Scanner;
Main.java
import java.util.Scanner;
do {
System.out.println("==== Library Book Management ====");
System.out.println("1. Add Book");
System.out.println("2. View Books");
System.out.println("3. Search Book");
System.out.println("4. Delete Book");
System.out.println("5. Exit");
System.out.print("Enter your choice: ");
Library Book Management System - Java Project
choice = sc.nextInt();
sc.nextLine(); // consume newline
switch (choice) {
case 1: library.addBook(); break;
case 2: library.viewBooks(); break;
case 3: library.searchBook(); break;
case 4: library.deleteBook(); break;
case 5: System.out.println("Exiting..."); break;
default: System.out.println("Invalid choice. Try again.");
}
} while (choice != 5);
sc.close();
}
}