Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

#include using namespace std; class DogLicense{ public: void SetYear(int yearRegistered); void CreateLicenseNum(int customID); int GetLicenseNum() const; private: int licenseYear; int licenseNum; }; void DogLicense::SetYear(int yearRegistered)

#include using namespace std;

class DogLicense{ public: void SetYear(int yearRegistered); void CreateLicenseNum(int customID); int GetLicenseNum() const; private: int licenseYear; int licenseNum; };

void DogLicense::SetYear(int yearRegistered) { licenseYear = yearRegistered; return; }

// FIXME: Write CreateLicenseNum()

/* Your solution goes here */

int DogLicense::GetLicenseNum() const { return licenseNum; }

int main() { DogLicense dog1;

dog1.SetYear(2014); dog1.CreateLicenseNum(777); cout

return 0; }

image text in transcribed

Challenge 15.2.2: Basic class definition Activity Define the missing function licenseNum is created as: (100000 customID) license Year. Sample outpu Dog license: 77702014 void Create LicenseNumCint customID int GetLicenseNumO const 9 private int license Year; int licenseNum 11 12 13 14 void DogLicense: :SetYear(int yearRegisteredD 1 licenseYear yearRegistered 15 return 17 19 FIXME: Write Create LicenseNumO 20 21 Your solution goes here 22 23 int DogLicense Get LicenseNumO const 1 24 return licenseNum Run Feedback

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Expert Performance Indexing In SQL Server

Authors: Jason Strate, Grant Fritchey

2nd Edition

1484211189, 9781484211182

Students also viewed these Databases questions