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
xz_007 [3.2K]
3 years ago
13

Write the definition of a class Clock. The class has no constructors and three instance variables. One is of type int called hou

rs, initialized to 12, another is of type boolean called isTicking, initialized to true, and the last one is of type Integer called diff, initialized to 5.
A) Public class Clock {
B) Private int hours = 12;
C) Private boolean isTicking = true;
D) Private Integer diff = 5;
Computers and Technology
1 answer:
maksim [4K]3 years ago
3 0

Answer:

Following are the program definition in the Java Programming Language.

//define a class

public class Clock

{

//set integer type variable and initialize value

private int hours=12;

//set boolean type variable and initialize value

private boolean isTicking=true;

//set integer type variable and initialize value

private Integer diff=5;

}

Explanation:

Following are the description of Code.

  • Firstly define a class "Clock" with the "private" access modifier.
  • Then,  set the integer data type variable "hours" with the "private" access modifier and assign value 12 in that class.
  • After that, set the boolean data type variable "isTicking" with the "private" access modifier and assign value "true".
  • Finally set Integer class variable "diff" with the the private access modifier and assign value 5.
You might be interested in
A manufacturer of machine tools creates a spreadsheet of tools and the cost for those. The spreadsheet has four fields: name of
iragen [17]

The question above has multiple answers:


<span>1.       </span>Sort the data in the field "name of the tool" in ascending order alphabetically.

<span>2.       </span> Sort the data in the field “number of tools” in ascending order.

<span>3.       </span>Sort the data in ascending order of cost per tool.

<span>4.       </span>Sort the data in ascending order of total cost.

The answer is 3. Sort the data in ascending order of cost per tool


You can always make your spreadsheet work a bit more organized by sorting your data. In this case, what is required from the manufacturer of the tools is to sort the data so that someone else is able to find out which tool costs the most. Basically, the price of the tool which is the highest is required to be known. Therefore, the manufacturer of the tools should Sort the data in ascending order of cost per tool.






3 0
3 years ago
1. Railroad tracks present no problems for a motorcyclist.
Yuki888 [10]

Answer: 1 is A

2 is D

Explanation:

3 0
3 years ago
What is heaven backwards?
sweet-ann [11.9K]
It is Nevaeh backwards hope that helps! :3 and feel free to pm me if you have anymore questions! :3
5 0
3 years ago
Read 2 more answers
Consider the helicopter of Example 2.1, but with a slightly different definition of the input and output. Suppose that, as in th
anzhelika [568]

Answer:

Solution: In this case, the system can be modeled as a function with two output signals,

S: (R  --> R) --> (R --> R)^{2}

where

(S(T_{y}))(t) = (x(t), y(t))

where(x(t), y(t)) is the position of the tail in they plane. This model Is Clearly not linear. If the  Input torque doubles, for example, the output values will not double. In fact, the output values are constrained to lie on a circle centered at the origin, regardless of the Input. For this reason, the model is BIBO stable. The output is always bounded. Thus, while our previous model was linear and unstable, this one Is nonlinear and stable. Which model is more useful?

3 0
3 years ago
Write a date transformer program using an if/elif/else statement to transform a numeric date in month/day format to an expanded
boyakko [2]

I wrote it in Python because it was quick so i hope this is helpful

Answer:

date = input('Enter Date: ')

split_date = date.split('/')

month = split_date[0]

day = split_date[1]

if month == '1':

   english_month = 'January'

   spanish_month = 'Enero'

elif month == '2':

   english_month = 'February'

   spanish_month = 'Febrero'

elif month == '3':

   english_month = 'March'

   spanish_month = 'Marzo'

elif month == '4':

   english_month = 'April'

   spanish_month = 'Abril'

elif month == '5':

   english_month = 'May'

   spanish_month = 'Mayo'

elif month == '6':

   english_month = 'June'

   spanish_month = 'Junio'

elif month == '7':

   english_month = 'July'

   spanish_month = 'Julio'

elif month == '8':

   english_month = 'August'

   spanish_month = 'Agosto'

elif month == '9':

   english_month = 'September'

   spanish_month = 'Septiembre'

elif month == '10':

   english_month = 'October'

   spanish_month = 'Octubre'

elif month == '11':

   english_month = 'November'

   spanish_month = 'Noviembre'

elif month == '12':

   english_month = 'December'

   spanish_month = 'Diciembre'

US_English = f'{english_month} {day}'

International_Spanish = f'{day} {spanish_month}'

print(f'US English Form: {US_English}')

print(f'International Spanish Form: {International_Spanish}')

Input:

3/5

Output:

US English Form: March 5

International Spanish Form: 5 Marzo

Explanation:

You start by taking input from the user then splitting that at the '/' so that we have the date and the month in separate variables. Then we have an if statement checking to see what month is given and when the month is detected it sets a Spanish variable and an English variable then prints it to the screen.

Hope this helps.

7 0
3 years ago
Other questions:
  • Melissa and Sue want to show a presentation to twenty employees using a presentation while using a projector. They learn that th
    12·2 answers
  • The term "Cloud" refers to what option(s) below? (Select all that apply)
    13·1 answer
  • How does technology make America great?​
    10·1 answer
  • if you wanted to round $3.99 located in cell b3, to the nearest dollar, what is the correct microsoft excel formula? a.=round(0.
    10·1 answer
  • Write a program that dose the following:
    9·1 answer
  • What can be done to solve unemployment problem?​
    11·1 answer
  • Someone please help ASAP will brainlist
    9·2 answers
  • Most file managers include a way to create a folder through the save dialog box. true or false?
    9·1 answer
  • Phân tích 5 phương hướng nhiệm vụ phát triển nông -lâm -ngư nghiệp ở nước ta hiện nay
    11·1 answer
  • ________ is the use of information technology to support the sharing of content among networks of users.
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!