Correct option is C
The correct HTML element for displaying an image is <img>, not <image>.
Placing the <img> inside <p>...</p> inserts the image within the next paragraph as requested.
src specifies the image file (Sample.gif), while height and width control its rendered size (here, 100% of the containing block).
Option (a) and (d) are invalid because <image> is not an HTML tag.
Option (b) wraps the image in an anchor <a> without an href and does not create a paragraph.
Hence, (c) is the valid and semantically appropriate choice.
Placing the <img> inside <p>...</p> inserts the image within the next paragraph as requested.
src specifies the image file (Sample.gif), while height and width control its rendered size (here, 100% of the containing block).
Option (a) and (d) are invalid because <image> is not an HTML tag.
Option (b) wraps the image in an anchor <a> without an href and does not create a paragraph.
Hence, (c) is the valid and semantically appropriate choice.
Important Key Points
- Tag to use: <img> is the correct self-closing/void element for images in HTML.
- Inside a paragraph: Wrapping <img> with <p>...</p> places it in a paragraph block.
- Attributes: src is required; height/width accept pixels or percentages relative to the container.
- Accessibility: Prefer adding alt="..." to describe the image for screen readers and broken-image cases.
- Void element: <img> has no closing tag; write <img ...> (HTML) or <img ... /> (XHTML-style).
- Responsive tip: Often better to control sizing via CSS (e.g., max-width:100%; height:auto;).
Knowledge Booster
- Why (a) & (d) are wrong: <image> is not defined in HTML; browsers won’t recognize it.
- Why (b) isn’t suitable: <a> without href is not a link and does not create a paragraph; requirement was specifically to add the image in the next paragraph.
- Best practice: Use semantic HTML and CSS for layout; include alt text and consider loading="lazy" for performance.