Question: Write an interactive version of the InchesToFeet class that accepts the inches value from a user. import java.util.Scanner; This is what was given: class InchesToFeetInteractive
Write an interactive version of the InchesToFeet class that accepts the inches value from a user.
import java.util.Scanner;
This is what was given: class InchesToFeetInteractive { public static void main(String[] args) {// Modify code below final int INCHES_IN_FOOT = 12; int inches = 86; int feet; int inchesLeft; feet = inches / INCHES_IN_FOOT; inchesLeft = inches % INCHES_IN_FOOT; System.out.println(inches + " inches is " + feet + " feet and " + inchesLeft + " inches");
} }
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
