subject

Define the missing method. licenseNum is created as: (100000 * customID) + licenseYear. Sample output: Dog license: 77702014

Here is the code already in the program:

// Code from file DogLicense. java
public class DogLicense {
private int licenseYear;
private int licenseNum;

public void setYear(int yearRegistered) {
licenseYear = yearRegistered;
return;
}

// FIXME: Write createLicenseNum()

/* Your solution goes here */

public int getLicenseNum() {
return licenseNum;
}
}
// end

// Code from file CallDogLicense. java
public class CallDogLicense {
public static void main (String [] args) {
DogLicense dog1 = new DogLicense();

dog1.setYear(2014);
dog1.createLicenseNum(777);
System. out. println("Dog license: " + dog1.getLicenseNum());

return;
}
}
// end

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 14:20
Cengagenowv2 is a comprehensive online learning tool. using cengagenowv2, you may access all of the following except: 2. each time you log in, cengagenowv2 automatically performs a system check and informs you if your computer does not meet the cengagenowv2 system requirements. 3. which tab/page allows you to easily track your assignment scores, number of submissions, time spent, as well as the ability view assign
Answers: 3
question
Computers and Technology, 23.06.2019 21:00
Which set of steps will organize the data to only show foods with more than 100 calories and rank their sugar content from greatest to least?
Answers: 1
question
Computers and Technology, 23.06.2019 21:20
In microsoft word, when you highlight existing text you want to replace, you're in              a.  advanced mode.    b.  automatic mode.    c.  basic mode.    d.  typeover mode
Answers: 1
question
Computers and Technology, 24.06.2019 01:00
What are two ways to access the options for scaling and page orientation? click the home tab, then click alignment, or click the file tab. click the file tab, then click print, or click the page layout tab. click the page layout tab, or click the review tab. click the review tab, or click the home tab?
Answers: 2
You know the right answer?
Define the missing method. licenseNum is created as: (100000 * customID) + licenseYear. Sample outpu...
Questions
question
Geography, 05.07.2019 10:30
Questions on the website: 13722363