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, 21.06.2019 15:30
Some of the items below indicate the steps required to move a slide to a different location in a presentation. select those steps and indicate the order in which they should be performed to move the slide. (for example, if an item describes what you do first, select 1.) included in the list are items that are not part of the process. for these items, select n/a, an abbreviation for not applicable. 1 — first 2 — second 3 — third 4 — fourth 5 — fifth 6 — sixth n/a — not applicable drag the slide to the desired place. enter the slide position desired. hold the mouse button down. select move from the tools menu. select the slide. switch to the notes view.
Answers: 3
question
Computers and Technology, 23.06.2019 22:00
Jackson, who works in the finance department of a company, is holding a seminar for other employees on how to file taxes. only three employees sign up to attend the seminar. which device can he use to share his presentation with a group of three employees?
Answers: 1
question
Computers and Technology, 24.06.2019 05:30
How do i get rid of my member ship for
Answers: 2
question
Computers and Technology, 25.06.2019 04:30
What should be used when performing vehicle maneuvers?
Answers: 1
You know the right answer?
Define the missing method. licenseNum is created as: (100000 * customID) + licenseYear. Sample outpu...
Questions
question
History, 30.10.2020 07:30
question
History, 30.10.2020 07:30
question
Spanish, 30.10.2020 07:30
question
Mathematics, 30.10.2020 07:30
question
Advanced Placement (AP), 30.10.2020 07:30
question
Mathematics, 30.10.2020 07:30
question
History, 30.10.2020 07:30
question
English, 30.10.2020 07:30
Questions on the website: 13722363