9. What is the difference between div and span?
Both are generic containers. <div> is normally used as a block-level structural container, while <span> is an inline phrasing container. Neither adds meaningful semantics by itself.
Key Takeaways
- div and span are generic.
- Use semantic elements when one accurately describes the content.
Knowledge Check
Which statement is correct?