Problem Statement
Which statement correctly describes the difference between head and body sections?
Explanation
The head contains metadata like title, character encoding, and stylesheet links. Users do not see this content. The body contains all visible content like text, images, and videos. Both sections are required in every HTML document.
Code Solution
SolutionRead Only
<!DOCTYPE html>
<html>
<head>
<!-- Metadata - Not visible on page -->
<title>My Website</title>
<meta charset="UTF-8">
<meta name="description" content="Website description">
<link rel="stylesheet" href="styles.css">
</head>
<body>
<!-- Visible content -->
<h1>Welcome to My Website</h1>
<p>This text is visible to users</p>
<img src="logo.png" alt="Logo">
</body>
</html>