hollyhill2005
hollyhill2005 3d ago • 10 views

HTML Images quiz for Grade 8 Computer Science

Hey everyone! 👋 Getting ready for your Computer Science class and need a quick refresh on HTML images? Or maybe you're a teacher looking for a fun quiz for your Grade 8 students? This guide and quiz are perfect for mastering how to add and style images on web pages! Let's dive in! 💻
💻 Computer Science & Technology
🪄

🚀 Can't Find Your Exact Topic?

Let our AI Worksheet Generator create custom study notes, online quizzes, and printable PDFs in seconds. 100% Free!

✨ Generate Custom Content

1 Answers

✅ Best Answer
User Avatar
adam.schneider Mar 16, 2026

📸 Quick Study Guide: HTML Images

  • 🖼️ The `` tag is used to embed an image in an HTML page. It is an empty tag, meaning it has no closing tag.
  • 🔗 The `src` attribute is essential and specifies the path (URL) to the image file. Example: ``.
  • ✏️ The `alt` attribute provides an "alternative text" for an image. This text is displayed if the image cannot be loaded (e.g., due to a broken path, slow connection) and is crucial for accessibility (screen readers). Example: `Description of image`.
  • 📏 The `width` and `height` attributes are used to specify the dimensions of an image in pixels. Example: ``.
  • 🌐 Images can be linked from the same folder (relative path) or from a web address (absolute URL).
  • 💡 Best practice: Always include the `alt` attribute for accessibility and SEO.

🧠 Practice Quiz: HTML Images

  1. Which HTML tag is used to embed an image on a web page?
    A) ``
    B) ``
    C) ``
    D) ``
  2. Which attribute is used to specify the path to an image file?
    A) `link`
    B) `href`
    C) `source`
    D) `src`
  3. What does the `alt` attribute provide for an image?
    A) The alignment of the image.
    B) The alternative text for the image, displayed if it cannot be loaded.
    C) The animation style for the image.
    D) The border color of the image.
  4. If you want to set the width of an image to 200 pixels and the height to 150 pixels, which attributes would you use?
    A) `size="200x150"`
    B) `dimension="200,150"`
    C) `width="200" height="150"`
    D) `imgsize="200,150"`
  5. Which of the following is an example of a correctly formed `` tag?
    A) `A beautiful landscape`
    B) ``
    C) `A beautiful landscape`
    D) `A beautiful landscape`
  6. Why is the `alt` attribute important for accessibility?
    A) It makes the image load faster.
    B) It allows screen readers to describe the image content to visually impaired users.
    C) It automatically resizes the image for different devices.
    D) It adds a caption below the image.
  7. Is the `` tag an empty tag or a container tag?
    A) It is a container tag because it holds the image content.
    B) It is an empty tag because it does not have a closing tag.
    C) It depends on the image file type.
    D) It is an empty tag, but it requires a closing `/` in HTML5.
Click to see Answers

1. C) ``
2. D) `src`
3. B) The alternative text for the image, displayed if it cannot be loaded.
4. C) `width="200" height="150"`
5. C) `A beautiful landscape`
6. B) It allows screen readers to describe the image content to visually impaired users.
7. B) It is an empty tag because it does not have a closing tag.

Join the discussion

Please log in to post your answer.

Log In

Earn 2 Points for answering. If your answer is selected as the best, you'll get +20 Points! 🚀