Question: java .. A bookstore owner needs to keep track of the books in his store. Each book in his bookstore has a unique number, a
java ..
A bookstore owner needs to keep track of the books in his store. Each book in his bookstore has a unique number, a title, an author, a subject, a price, and a number of copies in the bookstore. He keeps a list of his books in a file called myBooks.in. Building an application to help this bookstore owner, which reads the books from the myBooks.in file each morning, keeps track of each books sold by decreasing the number of copies remaining in the bookstore, and then re-saves the books to a new file.
The app should display a menu to do the following:
- Display all book information in the bookstore.
- Display all books for a certain author
- Display all books for a certain subject
- Display a list of books that with number of copies remaining = 0,
- Display all books sorted according to price (from most expensive to least expensive)
- Sell a certain book (the book number is given by the user). The number of copies remaining should be
decreased after selling a book.
- Give the total amount of money for all the books that was sold.
- Save the new list of books to an output file (the file name is also given by the user). You will need three classes: Book, BookStore, (which has a list of Books), and TestingBookStore (with the main method).
input file
001, Java Java Java, Ahmed Khan, IT, 40.50, 10 002, Nature in the desert, Ali Hassan, Biology, 55.75, 4 003, The Internet for Dummies, Mohammed Ali, IT, 33.50, 6 004, Under the Sea, Mohammed Ali, Biology, 70.00, 0 005, Outer Space Physics, Ali Hassan, Physics, 100.99, 0 006, Grays Anatomy, Alex Gray, Medicine, 300.00, 10
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
