HTML & CSS · Middle · Question 66 of 75

Why is there a small gap under an <img> inside a <div>?

Explanation

The space below the baseline is reserved for letters like "g" and "y". Most CSS resets set img { display: block; } for this reason.

Further reading

Problem with a question

HTML & CSS · Middle · question 66

Test yourself

Take the HTML & CSS · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz