Advertisement
Guest User

Untitled

a guest
Jul 27th, 2017
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.80 KB | None | 0 0
  1. //Customer class implementation
  2. //Also known as: I've Been Running Arch Linux On Virtual Machines For A Week And It's Still Very Usable
  3.  
  4. #include <iostream>
  5.  
  6. using namespace std;
  7.  
  8. #include "customer.h"
  9.  
  10. //Constructors:
  11. //Default constructor
  12. Customer :: Customer() {
  13.          custnum = 0;
  14.          name = "";
  15.          }
  16.          
  17. //Settable constructor
  18. Customer :: Customer(int custnum, string name) {
  19.          custnum = newnum;
  20.          name = newname;
  21.          }
  22.          
  23. //Functions
  24.  
  25. void Customer :: print(void) {
  26.      cout << "-------- Customer Information --------" << endl;
  27.      cout << "Customer Number:" << custnum << endl;
  28.      cout << "Customer Name: " << name << endl;
  29. }
  30.  
  31. void Customer :: store(int newnum, string newname) {
  32.      custnum = newnum;
  33.      name = newname;
  34.      }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement