import java.util.Scanner; class U1_L4_Activity_Two { public static void main(String[] args) { /* Write your code here */ Scanner scan = new Scanner(System.in); int inches; int feet; System.out.println("How many inches?"); inches = scan.nextInt(); feet = inches/12; System.out.println(inches + "\" equals " + feet + "\'" );
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter