Computer Science, asked by rasmita0026, 5 hours ago

(write in JAVA )write a program to computer/calculate and print volume of a cuboid (length x Breadth x Height) and
total surface area [2 x (length x breadth + breadth x
height + height x length) where length is 20,
breadth is 14 and height is 11.​

Answers

Answered by kamaldhod1984
1

GOOD NIGHT AND NICE DAY.

Answered by mishrashaily57
0

Explanation:

alculate Volume Of CuboidJava

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

import java.util.Scanner;

class VolumeOfCuboid

{

public static void main(String args[])

{

Scanner s= new Scanner(System.in);

System.out.println("Enter the length of Cubiod:");

double l=s.nextDouble();

System.out.println("Enter the breadth of Cubiod:");

double b=s.nextDouble();

System.out.println("Enter height of Cubiod:");

double h=s.nextDouble();

double volume= l*b*h;

System.out.println("Volume Of Cuboid is:" +volume);

}

}

Output :

1

2

3

4

5

6

7

Enter the length of Cubiod:

5

Enter the breadth of Cubiod:

10

Enter height of Cubiod:

10

Volume Of Cuboid is:500.00

Here Goes the online implementation tool for the above sample program # 1. Enter the values by line by line. If you encounter any problems while executing the program, do let

Similar questions