I am working on an assignment and would like an input if I am heading in a right direction. I am also stuck on specific guideline and I need assistance on how to complete it.
Here's what my assignment asking us to do:
Create a program that be used for keeping track of textbooks required and recommended for classes and the cost of those textbooks...
Right now I am trying to do one of many line formats such as:
"B<ISBN><Title>
- Define a book. The ISBN is a 13 digit number. The Title is a string of arbitrary length(ending with line break).
e.g : B 1234567890123 Programming for Dummies"
And this is what I have so far:
Code:
#include <iostream>
#include <string>
using namespace std;
int main() {
char input;
cout << "Please enter a single or double character that identifies the type of operation: "<< endl;
cin >> input;
string ISBN;
string TITLE;
switch ( input ){
case 'B':
//Stuck here...
break;
}
}
Now I am lost as in what the format wants me to do, do I make my own books, and when the user input "B" they will get all the possible book outputs? Or I am not understanding the requirements correctly.