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
NeTakaya
3 years ago
14

You are given a class named Clock that has one int instance variable called hours.

Computers and Technology
1 answer:
Vlad [161]3 years ago
7 0

Answer:

public Clock(int hours) {

       this.hours = hours;

   }

Explanation:

In Java programming language, Constructors are special methods that are called to initialize the variables of a class when a new object of the class is created with the new keyword. Consider the complete code for the class below;

<em>public class Clock {</em>

<em>    private int hours;</em>

<em>    public Clock(int hours) {</em>

<em>        this.hours = hours;</em>

<em>    }</em>

<em>}</em>

In this example above,  an object of this class can created with this statement Clock myclock = new Clock(6); This is a call to the constructor and passes a parameter (6) for hours

You might be interested in
Which page feature is used in long documents to assist readers in quickly finding information in the document without having to
irakobra [83]

Maybe it is Ctrl-F... is this what you're thinking of?

3 0
3 years ago
Read 2 more answers
Which of the following is a safe work practice to protect you from electrocution hazards?
Flura [38]
What are the answer choices?
7 0
3 years ago
In company a, there is a team that performs day-to-day it operations with a focus on security. they are responsible for a wide r
jasenka [17]

The security operation being carried out by this team is Administrative in nature.

<h3>What is the role of an Administrators?</h3>

An Administrators is known to be a person who works or handles the day-to-day deployment, operation and looking of an IT environment.

Note that their areas of concern are the systems, networks and applications as well as others and as such, The security operation being carried out by this team is Administrative in nature.

Learn more about  security operation from

brainly.com/question/371967

#SPJ1

6 0
2 years ago
6. Which is not considered a storage device a. USB Flash Drive b. External hard Drive c. MS-Windows d. Internal Hard Drive e. Me
Lana71 [14]

Answer:

MS-Windows

Explanation:

MS-Windows is an operating system not a storage device.

6 0
3 years ago
Is science fiction always set in the future
Natali5045456 [20]
Yes and No it all depends on how the author wants the poem how to be and become. Majority of the time science fiction is set for the future.
5 0
3 years ago
Other questions:
  • What is the order of arrangement of files and folders on a computer?
    15·1 answer
  • What is <br> central vision
    12·2 answers
  • How can you ensure that your web pages are compliant with a w3c standard?
    9·1 answer
  • What is a boolean in Java
    5·1 answer
  • what are the benefits of VolP? select all that apply. A:cheaper printings B:clearer calls C: faster download D: increased effici
    11·2 answers
  • I WILL GIVS BRAINLIEST IF U ANSWER THIS
    9·1 answer
  • How do you do 1.17.5, invert colors, on codehs?
    10·1 answer
  • Place the steps for attaching a file to a message in order from top to bottom.
    12·1 answer
  • Can someone help me with python
    10·1 answer
  • 2.Some artists look for ways to extend copyright for longer than the laws normally allow. Why do they do this?
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!