0 out of 464 challenges solved
Write a function `volume_cube` that calculates the volume of a cube given its side length. The volume of a cube is calculated using the formula:
\[ \text{Volume} = \text{side}^3 \]
#### Function Signature
```python [main.nopy]
def volume_cube(side: float) -> float:
pass
```
#### Input
- `side` (float): The length of a side of the cube. It is guaranteed to be a positive number.
#### Output
- Returns a float representing the volume of the cube.
#### Example Usage
```python [main.nopy]
print(volume_cube(3)) # Output: 27.0
print(volume_cube(2)) # Output: 8.0
print(volume_cube(5)) # Output: 125.0
```def volume_cube(side: float) -> float:
"""
Calculate the volume of a cube given its side length.
Args:
side (float): The length of a side of the cube.
Returns:
float: The volume of the cube.
"""
# Placeholder for the solution
pass