Multiple choice technology web technology

What is the correct HTML for inserting an image?

  1. <img>image.gif</img>

  2. <image src="image.gif" />

  3. <img href="image.gif />

  4. <img src="image.gif" />

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

The tag with the src attribute is the correct syntax for inserting images in HTML. Option A uses incorrect closing syntax (images are self-closing), option B uses a non-existent tag, and option C uses href instead of src.