โ† All Web Development Flashcard Decks

HTML and CSS Flashcards

7 cards from real Web Development practice questions. Tap to flip, then mark Knew It or Still Learning โ€” missed cards come back until you master them.

Read the first 7 HTML and CSS flashcards as text
  1. Which CSS unit is relative to the font-size of the root `` element?

    Answer: rem

    `rem` (root em) is always relative to the font-size set on the `` element, making it predictable regardless of nesting.

  2. What is the purpose of the HTML `` tag?

    Answer: It declares the character encoding the browser should use to interpret the document

    The charset meta tag tells the browser which encoding to use when reading the HTML bytes, ensuring characters render correctly.

  3. In CSS Grid, what does `grid-template-columns: repeat(3, 1fr)` create?

    Answer: Three equal-width columns that share the available space

    `1fr` is a fractional unit; three of them divide the available track space into three equal columns.

  4. Which HTML tag produces a thematic break (horizontal rule) between sections?

    Answer:

    `` represents a thematic break in content and renders as a horizontal line by default.

  5. What CSS property makes text lowercase regardless of how it is typed in HTML?

    Answer: text-transform: lowercase

    `text-transform: lowercase` converts all characters in the element to lowercase at render time without changing the source HTML.

  6. Which attribute on an `` tag opens the linked URL in a new browser tab?

    Answer: target="_blank"

    `target="_blank"` instructs the browser to open the href in a new browsing context (tab or window).

  7. In CSS, what does the `::before` pseudo-element do?

    Answer: Inserts generated content as the first child of the selected element

    `::before` creates a pseudo-element that becomes the first child of the selector and can display content via the `content` property.

How this page was made: written with AI tools. We have not yet matched this exam's facts to an official source, so confirm fees, dates and rules with the exam body. Not reviewed by a subject-matter expert. Editorial policy