1.Basic HTML page structure
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>My Page</title>
</head>
<body>
<h1>Hello World</h1>
</body>
</html>
High-frequency HTML coding questions used in real frontend interviews.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>My Page</title>
</head>
<body>
<h1>Hello World</h1>
</body>
</html>
<header></header>
<nav></nav>
<main>
<section></section>
<article></article>
</main>
<footer></footer>
<a href="https://example.com" target="_blank">
Visit Website
</a>
<img src="image.jpg" alt="Description">
<ul>
<li>HTML</li>
<li>CSS</li>
</ul>
<ol>
<li>JavaScript</li>
<li>Python</li>
</ol>
<table>
<tr>
<th>Name</th>
<th>Age</th>
</tr>
<tr>
<td>John</td>
<td>25</td>
</tr>
</table>
<form>
<input type="text" placeholder="Name">
<input type="email" placeholder="Email">
<button type="submit">Submit</button>
</form>
<input type="email">
<input type="date">
<input type="number">
<label for="email">Email</label>
<input id="email" type="email">
<audio controls>
<source src="song.mp3" type="audio/mpeg">
</audio>
<video controls width="300">
<source src="video.mp4" type="video/mp4">
</video>
<iframe src="page.html"></iframe>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- This is a comment -->
<a href="file.pdf" download>Download</a>
<figure>
<img src="img.jpg">
<figcaption>Caption</figcaption>
</figure>
<details>
<summary>More Info</summary>
<p>Hidden text</p>
</details>
<progress value="70" max="100"></progress>
<input type="text" required>
<input type="text" placeholder="Enter name">
<div>Block</div>
<span>Inline</span>
© < > &
<a href="page.html" target="_blank">Open</a>
<textarea placeholder="Message"></textarea>
<section>
<h2>Title</h2>
<p>Content</p>
</section>