Use clip-path to create a hexagonal-shaped image.
MediumProblem Statement
Use clip-path to create a hexagonal-shaped image.
Sample Output
The image is displayed in a hexagonal shape.
Limits
Time: 2s · Memory: 256 MB
Code Editor
00:00
<!DOCTYPE html>
<html>
<head>
<style>
/* Add CSS here to clip the image into a hexagon */
</style>
</head>
<body>
<img src="example.jpg" alt="Hexagon Image" class="hexagon" />
</body>
</html>
Expected Output
The image is displayed in a hexagonal shape.