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
daser333 [38]
3 years ago
10

There are 12 inches in a foot and 3 feet in a yard. Create a class named InchConversion. Its main() method accepts a value in in

ches from a user at the keyboard, and in turn passes the entered value to two methods. One converts the value from inches to feet, and the other converts the same value from inches to yards. Each method displays the results with appropriate explanation.
Computers and Technology
1 answer:
Dafna1 [17]3 years ago
7 0

Answer:

import java.util.Scanner;

public class InchConversion

{

public static void main(String[] args) {

    Scanner input = new Scanner(System.in);

   

 System.out.print("Enter inches: ");

 double inches = input.nextDouble();

 

 inchesToFeet(inches);

 inchesToYards(inches);

}

public static void inchesToFeet(double inches){

    double feet = inches / 12;

    System.out.println(inches + " inches = " + feet + " feet");

}

public static void inchesToYards(double inches){

    double yards = inches / 36;

    System.out.println(inches + " inches = " + yards + " yards");

}

}

Explanation:

In the inchesToFeet() method that takes one parameter, inches:

Convert the inches to feet using the conversion rate, divide inches by 12

Print the feet

In the inchesToYards() method that takes one parameter, inches:

Convert the inches to yards using the conversion rate, divide inches by 36

Print the yards

In the main:

Ask the user to enter the inches

Call the inchesToFeet() and inchesToYards() methods passing the inches as parameter for each method

You might be interested in
Which view is most often used to reorder slides in a presentation that has already been created?
riadik2000 [5.3K]

Answer:

Normal view

Explanation:

The normal view is best used because it is just to drag and drop

4 0
3 years ago
Read 2 more answers
What are the guided and unguided transmission media and what are the differences?
Ludmilka [50]

Answer:  They are forms of of carrying data from communication devices. The difference is the medium where the signal travels.

Explanation:

Hi, the difference between guided and unguided media is that in the guided media, the signal travels through a physical medium whereas, in unguided media, the signal travels through the air.  

Guided and unguided media are types of transmission media.

The transmission media carries electromagnetic signals, that transmit data between communicating devices like computers.

4 0
3 years ago
Which of the following is an example of data an Earth-observing satellite would collect?
Natalka [10]

Answer:

A

Explanation:

Hopefully this helps

4 0
2 years ago
Based on the information in the table, which of the following tasks is likely to take the longest amount of time when scaled up
kakasveta [241]

Answer:

Task A

Explanation:

8 0
3 years ago
A program executes 15 billion instructions. You are running this program in two systems: System A: has a processor with 3 GHz an
katrin2010 [14]

Answer:

CPU clock cycles = Instruction count x CPI.

CPU execution time =

= CPU clock cycles x Clock cycle.

= Instruction count x CPI x Clock cycle.

T =

I.

x CPI x C

Explanation:

i'm guessing

7 0
3 years ago
Other questions:
  • There are many differenttypes of models, but an individual DSS can consist of onlyone.
    15·1 answer
  • Sorry to bother you guys but for some reason it wont let me comment. How can i fix this?
    5·2 answers
  • Which button, when pressed, allows light from the subject to fall on the sensor?
    8·1 answer
  • Priscilla is providing the junior analysts in her firm with some real-world illustrations to explain some of the recommendations
    12·1 answer
  • According to the video, what kinds of projects would Computer Programmers be most likely to work on? Check all that apply.
    13·2 answers
  • Which actions are available in the Trust Center? Check all that apply.
    8·1 answer
  • Management of software development consist of?
    15·1 answer
  • Need the answer ASAP!!!!!!!!!!!!! I’ll mark brainliest if correct
    8·1 answer
  • What is a common use for append queries?
    14·2 answers
  • With
    10·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!