#include <iostream>
//#include <stdio.h>
#include <string.h>
using namespace std;
/* add supporting structures */
struct date
{
int month;
int day;
int year;
};
struct name
{
char firstName[25];
char middleInitial;
char lastName[40];
};
struct address
{
char street1[25]; /* first line of street address */
char street2[25]; /* second line, optional */
char city[25]; /* name of city */
char state[3]; /* 2-letter state abreviation */
char zip[6]; /* 5-digit ZIP code */
char plusFour[5]; /* 4-digit ZIP code extension */
};
struct height
{
int feet;
int inches;
};
/* the actual license structure that will contain all needed members */
class license
{
private:
string number; /* alpha numeric license number */
struct date birthDate; /* the date the driver was born */
struct name driverName; /* full name of driver */
struct date issueDate; /* date the license was issued */
struct date expirationDate; /* date the license will expire */
string endorsements; /* list of 1 or more letters or "NONE" */
char vehicleClass; /* single letter for class of vehicle (D=small vehicle) */
string restrictions; /* list of 1 or more letters (B=corrective lenses) or "NONE" */
char sex; /* single letter (M=male, F=female) */
struct height driverHeight; /* driver's height in feet and inches */
struct address driverAddress; /* driver's address */
public:
// empty constructor
license();
// initializing constructor
license(string aNumber, date aBirthDate, name aDriverName, date anIssueDate,
date anExpirationDate, string anEndorsements, char aVehicleClass,
string aRestrictions, char aSex, height aDriverHeight, address aDriverAddress);
};
// The license class member definitions follow:
license::license ()
{
}
// initializing constructor
license::license(string aNumber, date aBirthDate, name aDriverName, date anIssueDate,
date anExpirationDate, string anEndorsements, char aVehicleClass,
string aRestrictions, char aSex, height aDriverHeight, address aDriverAddress)
{
number = aNumber;
birthDate = aBirthDate;
driverName = aDriverName;
issueDate = anIssueDate;
expirationDate = anExpirationDate;
endorsements = anEndorsements;
vehicleClass = aVehicleClass;
restrictions = aRestrictions;
sex = aSex;
driverHeight = aDriverHeight;
driverAddress = aDriverAddress;
}
int main()
{
return 0;
}