Python Program to Find the Volume and Surface Area of a Cuboid

width = float(input("Enter the Width of a Cuboid: "))
height = float(input("Enter the Height of a Cuboid: "))
# Calculate the Surface Area
SA = 2 * (length * width + length * height + width * height)
# Calculate the Volume
Volume = length * width * height
# Calculate the Lateral Surface Area
LSA = 2 * height * (length + width)
# Print the Output
print("\nThe Surface Area of a Cuboid = %.2f " %SA)
print("The Volume of a Cuboid = %.2f" %Volume);
print("The Lateral Surface Area of a Cuboid = %.2f " %LSA)

OUTPUT:

Enter the Length of a Cuboid: 5
Enter the Width of a Cuboid: 6
Enter the Height of a Cuboid: 7
The Surface Area of a Cuboid = 214.00
The Volume of a Cuboid = 210.00
The Lateral Surface Area of a Cuboid = 154.00 
Sharing Is Caring

Leave a Comment