Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void fillCard ( Card cardInfo[],int &numberBooks)
- {
- cout<<"Please enter the ID number of the book: ";
- scanf(" %d",&cardInfo[numberBooks].bookID);
- fflush(stdin);
- cout<<endl;
- cout<<"Please enter the title of the book: ";
- scanf(" %s",cardInfo[numberBooks].title );
- fflush(stdin);
- cout<<endl;
- cout<<"Please enter the authors name: ";
- scanf(" %s",cardInfo[numberBooks].authors[numberBooks]);
- fflush(stdin);
- cout <<endl;
- cout <<"Please enter the ISBN-10 of the book you wish to add, if the ISBN contains an X substitute the X for the value of 10: ";
- cin >> cardInfo[numberBooks].isbn_10;
- scanf(" %d",&cardInfo[numberBooks].isbn_10);
- fflush(stdin);
- cout <<endl;
- cout <<"Please enter the ISBN-13 of the book you wish to add: " ;
- scanf(" %d",&cardInfo[numberBooks].isbn_13);
- fflush(stdin);
- cout<<endl;
- cout << "Please enter the amount of copies of this books we have : " ;
- scanf(" %d",&cardInfo[numberBooks].copies);
- fflush(stdin);
- cout<<endl;
- cout << "The amount of copies this book has: " << cardInfo[numberBooks].copies << endl;
- cardInfo[numberBooks].numberBorrowers=0;
- numberBooks++;
- }
Add Comment
Please, Sign In to add comment