Given the edge of the dodecahedron calculate its Volume. Volume is the amount of the space which the shapes takes up.

A **dodecahedron **is a 3-dimensional figure made up of 12 faces, or flat sides. All of the faces are pentagons of the same size.The word ‘dodecahedron’ comes from the Greek words dodeca (‘twelve’) and hedron (‘faces’).

**Formula:**

Volume = (15 + 7√5)*e^{3}/4

Where e is length of an edge.

Examples :

Input : side = 4 Output : 490.44 Input : side = 9 Output : 5586.41

## C++

`// CPP program to calculate ` `// Volume of dodecahedron ` `#include <bits/stdc++.h> ` `using` `namespace` `std; ` ` ` `// utility Function ` `double` `vol_of_dodecahedron(` `int` `side) ` `{ ` ` ` `return` `(((15 + (7 * (` `sqrt` `(5)))) / 4) ` ` ` `* (` `pow` `(side, 3))) ; ` `} ` `// Driver Function ` `int` `main() ` `{ ` ` ` `int` `side = 4; ` ` ` ` ` `cout << ` `"Volume of dodecahedron = "` ` ` `<< vol_of_dodecahedron(side); ` `} ` |

*chevron_right*

*filter_none*

## Java

`// Java program to calculate ` `// Volume of dodecahedron ` ` ` `import` `java.io.*; ` ` ` `class` `GFG ` `{ ` ` ` `// driver function ` ` ` `public` `static` `void` `main (String[] args) ` ` ` `{ ` ` ` `int` `side = ` `4` `; ` ` ` `System.out.print(` `"Volume of dodecahedron = "` `); ` ` ` `System.out.println(vol_of_dodecahedron(side)); ` ` ` `} ` ` ` ` ` `static` `double` `vol_of_dodecahedron(` `int` `side) ` ` ` `{ ` ` ` `return` `(((` `15` `+ (` `7` `* (Math.sqrt(` `5` `)))) / ` `4` `) ` ` ` `* (Math.pow(side, ` `3` `))); ` ` ` `} ` `} ` ` ` `// This code is contributed ` `// by Azkia Anam. ` |

*chevron_right*

*filter_none*

## Python3

`# Python3 program to calculate ` `# Volume of dodecahedron ` `import` `math ` ` ` `# utility Function ` `def` `vol_of_dodecahedron(side) : ` ` ` ` ` `return` `(((` `15` `+` `(` `7` `*` `(math.sqrt(` `5` `)))) ` `/` `4` `) ` ` ` `*` `(math.` `pow` `(side, ` `3` `))) ` ` ` `# Driver Function ` `side ` `=` `4` `print` `(` `"Volume of dodecahedron ="` `, ` ` ` `round` `(vol_of_dodecahedron(side), ` `2` `)) ` ` ` `# This code is contributed by Smitha Dinesh Semwal ` |

*chevron_right*

*filter_none*

## C#

`// C# program to calculate ` `// Volume of dodecahedron ` `using` `System; ` ` ` `public` `class` `GFG ` `{ ` ` ` ` ` `// utility Function ` ` ` `static` `float` `vol_of_dodecahedron(` `int` `side) ` ` ` `{ ` ` ` `return` `(` `float` `)(((15 + (7 * (Math.Sqrt(5)))) / 4) ` ` ` `* (Math.Pow(side, 3))) ; ` ` ` `} ` ` ` ` ` ` ` `// Driver Function ` ` ` `static` `public` `void` `Main () ` ` ` `{ ` ` ` `int` `side = 4; ` ` ` ` ` `Console.WriteLine(` `"Volume of dodecahedron = "` ` ` `+ vol_of_dodecahedron(side)); ` ` ` `} ` `} ` ` ` `/* This code is contributed by vt_m.*/` |

*chevron_right*

*filter_none*

## PHP

`<?php ` `// PHP program to calculate ` `// Volume of dodecahedron ` ` ` `// utility Function ` `function` `vol_of_dodecahedron(` `$side` `) ` `{ ` ` ` `return` `(((15 + (7 * (sqrt(5)))) / 4) ` ` ` `* (pow(` `$side` `, 3))) ; ` `} ` ` ` ` ` `// Driver Function ` ` ` `$side` `= 4; ` ` ` `echo` `(` `"Volume of dodecahedron = "` `); ` ` ` `echo` `(vol_of_dodecahedron(` `$side` `)); ` ` ` `// This code is contributed by vt_m. ` `?> ` |

*chevron_right*

*filter_none*

Output :

Volume of dodecahedron = 490.44

## Recommended Posts:

- Program to calculate volume of Ellipsoid
- Program to calculate volume of Octahedron
- Calculate volume and surface area of a cone
- Calculate Volume and Surface area Of Sphere
- Program to calculate area and volume of a Tetrahedron
- Calculate volume and surface area of Torus
- Program to calculate Volume and Surface area of Hemisphere
- Calculate Volume, Curved Surface Area and Total Surface Area Of Cylinder
- Program for Surface area of Dodecahedron
- Program for volume of Pyramid
- Volume of cube using its space diagonal
- Maximize volume of cuboid with given sum of sides
- Program for Volume and Surface Area of Cuboid
- Surface Area and Volume of Hexagonal Prism
- Program for Volume and Surface Area of Cube

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.