Guest User

Untitled

a guest
Apr 20th, 2018
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.09 KB | None | 0 0
  1. void fillCard ( Card cardInfo[],int &numberBooks)
  2. {
  3.  
  4.         cout<<"Please enter the ID number of the book: ";
  5.         scanf("%d",cardInfo[numberBooks].bookID)
  6.         cout<<endl;
  7.         cout<<"Please enter the title of the book: ";
  8.         scanf("%s",cardInfo[numberBooks].title )
  9.         cout<<endl;
  10.         cout<<"Please enter the authors name: ";
  11.         scanf("%s",cardInfo[numberBooks].authors[numberBooks]);
  12.         cout <<endl;
  13.         cout <<"Please enter the ISBN-10 of the book you wish to add, if the ISBN contains an X substitute the X for t\he value of 10: ";
  14.         cin >> cardInfo[numberBooks].isbn_10;
  15.         scanf("%d",cardInfo[numberBooks].isbn_10);
  16.         cout <<endl;
  17.         cout <<"Please enter the ISBN-13 of the book you wish to add: " ;
  18.         scanf("%d",cardInfo[numberBooks].isbn_13);
  19.         cout<<endl;
  20.         cout << "Please enter the amount of copies of this books we have : " ;
  21.         scanf("%d",cardInfo[numberBooks].copies);
  22.         cout<<endl;
  23.         cout << "The amount of copies this book has: " << cardInfo[numberBooks].copies << endl;
  24.         cardInfo[numberBooks].numberBorrowers=0;
  25.         numberBooks++;
  26.     }
Add Comment
Please, Sign In to add comment