Question: in JAVA Complete the following skeleton code so that it can compute the circumference of a rect, square, or triangle. ================== import java.util.Scanner; public class
in JAVA Complete the following skeleton code so that it can compute the circumference of a rect, square, or triangle.
==================
import java.util.Scanner;
public class Question1x {
public static void main(String[] args) {
Scanner input = new Scanner(System.in);
// compute the circumference of a shape
// See sample output
System.out.println( "I can compute the circumference of one of the followings: Rect, Square, or Triangle " );
System.out.print( "Enter a shape: " );
String shape = input.nextLine().trim();
int circum = 0 ;
int side1, side2, side3;
// Your code here
System.out.println( "The circumference is : " + circum);
input.close();
}
}
=======================
The following is a sample output.

Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
