1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
TiliK225 [7]
2 years ago
12

Look at the following partial class definition, and then respond to the questions that follow it:

Computers and Technology
1 answer:
zhannawk [14.2K]2 years ago
4 0

Solution :

a.

public Book($\text{String title}$, String author, $\text{String publisher}$, int $\text{copiesSold}$) {

 this.$\text{title}$ = $\text{title}$;

 this.$\text{author}$ = $\text{author}$;

 this.$\text{publisher}$ = $\text{publisher}$;

 this.$\text{copiesSold}$ = $\text{copiesSold}$;

b). $\text{public String}$ getTitle() {

 return $\text{title}$;

}

$\text{public void}$ setTitle($\text{String title}$) {

 this.$\text{title}$ = $\text{title}$;

}

$\text{public String}$ getAuthor() {

 return author;

}

$\text{public void}$ setAuthor(String author) {

 this.$\text{author}$ = $\text{author}$;

}

$\text{public String}$ getPublisher() {

 return $\text{publisher}$;

}

$\text{public void}$ setPublisher(String $\text{publisher}$) {

 this.$\text{publisher}$ =$\text{publisher}$;

}

public int get$\text{copiesSold}$() {

 return $\text{copiesSold}$;

}

$\text{public void}$ set$\text{copiesSold}$(int $\text{copiesSold}$) {

 this.$\text{copiesSold}$ = $\text{copiesSold}$;

}

You might be interested in
CODING TIME
Fynjy0 [20]

Answer:

food_list = ['rice', 'beans','yam', 'bread', 'pasta', 'cocoa','tea']

one_more = ['meat']

extend_list = food_list + one_more

print(extend_list)

Output : ['rice', 'beans','yam', 'bread', 'pasta', 'cocoa','tea', 'meat']

food_list.append('milk')

print(food_list)

Output : ['rice', 'beans','yam', 'bread', 'pasta', 'cocoa','tea', 'milk']

food_list.insert(0, 'cake')

print(food_list)

Output : ['cake', 'rice', 'beans','yam', 'bread', 'pasta', 'cocoa','tea']

flowers = ['rose', 'hibiscus', 'lily']

flowers.remove('rose')

print(flowers)

Output : ['hibiscus', 'lily']

To remove rose using pop()

flowers.pop(0)

Explanation:

The + operator and append method adds elements to the end of an existing list item.

The insert method adds element at the specified index

Remove method deletes element by stating the name of the element to be deleted while pop deletes element using the index value of the element.

7 0
2 years ago
Zachary was frustrated. His computer was running very slowly and he was worried that it was reducing his productivity on the job
Irina18 [472]

Literally QuickTime....I hate brainly

4 0
3 years ago
Which font style is said to be slightly above the other line of text?
Keith_Richards [23]
I think the answer would be "superscript"
8 0
3 years ago
Read 2 more answers
Assume that month is an int variable whose value is 1 or 2 or 3 or 5 ... or 11 or 12. Write an expression whose value is "jan" o
Tamiku [17]

Answer:

The code is given below

Explanation:

The correct syntax would be to place appropriate parenthesis.

(month==1?"jan":(month==2?"feb":(month==3?"mar":(month==4?"apr":(month==5?"may":(month==6?"jun":(month==7?"jul":(month==8?"aug":(month==9?"sep":(month==10?"oct":(month==11?"nov":"dec")))))))))));

Similarly, you can also use the following code:

String[] months = { "jan", "feb", "mar", "apr", "may", "jun", "jul", "aug", "sep", "oct", "nov", "dec" };

int month = 1;

String monthDescription = months[month - 1];

7 0
3 years ago
Surprisingly, many of us may be unknowing victims of botnets. Because of the rising sophistication of botnet schemes, your compu
Virty [35]

Answer:

a. Simple rules

1. Upgrade your operating system

2. Upgrade your softwares regularly

3. Upgrade your browser when new additions are available

4. Change your password very often

b. Suspensious signs

1. The operating system and programs take a longer while to start up.

2. It shows lack of storage space despite having space

3. The PC crashes regularly

4. If the sent mails are received as spam

5. The hard disk is working excessively while no programs are currently running

C. All the part of a security incident should be logged.

Explanation:

a. Simple rules

1. Upgrade your operating system

2. Upgrade your softwares regularly

3. Upgrade your browser when new additions are available

4. Change your password very often

b. Suspensious signs

1. The operating system and programs take a longer while to start up.

2. It shows lack of storage space despite having space

3. The PC crashes regularly

4. If the sent mails are received as spam

5. The hard disk is working excessively while no programs are currently running

Explanation:

C. All the part of a security incident should be logged.

7 0
2 years ago
Other questions:
  • Which term collectively describes hard disks, CDs, and flash drives?
    11·2 answers
  • Assuming that the message variable contains the string "Happy holidays", the statement message.find("days"); returns a. -1b. 10c
    6·1 answer
  • If a tv was showing a flat black or blue screen or had "snow", what steps would you take to fix it? Give an example of the direc
    11·1 answer
  • Which 3D game has Bentley the Bear collect gems while avoiding enemy trees, bees, ghosts, skeletons, and Berthilda the witch?
    9·1 answer
  • Refer to the method f: Public int f( int k, int n ) { if( n == k ) return k; else if( n > k ) return f( k, n - k ); else retu
    8·1 answer
  • On the Format tab, which group allows you to select a different font for a chart?
    7·2 answers
  • 10010 - 1011 binary subtraction​
    5·1 answer
  • You are developing a Website that is going to be viewed extensively on smartphones and tablets. Which of the following should yo
    7·1 answer
  • Which influence on spending deals with the motivation to<br> purchase a product?
    12·1 answer
  • In order to get the maximum functionality out of a device that is plugged in, a user should download the specific ___ for that d
    10·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!