HTML/CSSQuestion 02 of 14
div vs span
Answer out loud or in your head first, then compare.
Answer
Neither element carries semantic meaning. By default div is a block element and span is inline.
HTML
<div class="card">
Status: <span class="status">active</span>
</div>In practice: div groups part of a layout, and span marks out part of a text or other inline content.
To be precise: CSS can change their display, but that doesn't change the element's semantics. A default span doesn't behave like a rectangular block with a set width and height.
How did it go? Be honest — “Not yet” puts the question on your review list.