Each student will have to build a bookstore management system for adding, deleting, or searching for books in the store. Each book will have a title (string), bin number (four digit integer), and a price (double). When the program starts, it will load existing book information from a text file and when the program exits, it will save all changes made while running the program to that same file. After the book information is loaded from the file ( In this phase all you need to do is just print a message that the book information is loaded, but you don’t really open any files or load anything) , the program will display the following main menu to the user: Please Select an Operation (1-4): 1- Add a Book 2- Remove a Book 3- Search for a Book 4- Exit System 2 This menu will keep showing after each time a user selects an operation and that operation is performed. When the user selects operation 4 (exit system), the program will load all changes (updates) to the file ( In this phase all you need to do is just print a message that the book information is updated, but you don’t really open any files or update anything) and will then exit. Your program should at least contain the following functions: void displayMainMenu(); // displays the main menu shown above void addBook(); // adds information for a new book void removeBook(); // removes information of old book void searchForBook(); // searches for a book in the store void uploadDataFile(); // uploads book data from file void updateDataFile(); // saves book data updates to file For this phase those functions are just void functions that will mostly contain printf statements just to print what they are supposed to do. In later
Each student will have to build a bookstore management system for adding, deleting, or searching for books in the store. Each book will have a title (string), bin number (four digit integer), and a price (double). When the
After the book information is loaded from the file ( In this phase all you need to do is just print a message that the book information is loaded, but you don’t really open any files or load anything) , the program will display the following main menu to the user:
Please Select an Operation (1-4):
1- Add a Book
2- Remove a Book
3- Search for a Book
4- Exit System
2
This menu will keep showing after each time a user selects an operation and that operation is performed. When the user selects operation 4 (exit system), the program will load all changes (updates) to the file ( In this phase all you need to do is just print a message that the book information is updated, but you don’t really open any files or update anything) and will then exit.
Your program should at least contain the following functions:
void displayMainMenu(); // displays the main menu shown above
void addBook(); // adds information for a new book
void removeBook(); // removes information of old book
void searchForBook(); // searches for a book in the store
void uploadDataFile(); // uploads book data from file
void updateDataFile(); // saves book data updates to file
For this phase those functions are just void functions that will mostly contain printf statements just to print what they are supposed to do. In later phases, the function prototypes will change and the functions will do more.
Trending now
This is a popular solution!
Step by step
Solved in 2 steps