(Properties, Functions, Elements, & Tables) Flashcards
7 cards from real CSS practice questions. Tap to flip, then mark Knew It or Still Learning โ missed cards come back until you master them.
Read the first 7 (Properties, Functions, Elements, & Tables) flashcards as text
Which CSS property controls whether an element is treated as block, inline, flex, or grid?
Answer: display
display determines the box type and layout behavior of an element.
What does the CSS rgba() function add compared to rgb()?
Answer: An alpha (transparency) channel
rgba() adds a fourth value, alpha, that sets the color's opacity.
Which HTML element provides a title or description for a table?
Answer:
defines a caption (title) for a table, placed inside the element.
Which property sets the thickness, style, and color of an element's border in one line?
Answer: border
The shorthand border property sets width, style, and color together.
What does 'margin: 0 auto' commonly accomplish for a block element?
Answer: Horizontally centers it within its container
margin: 0 auto centers a fixed-width block element horizontally by balancing left and right margins.
Which property changes the mouse cursor when hovering over an element?
Answer: cursor
The cursor property sets which mouse cursor appears, such as pointer or default.
Which CSS property makes text bold?
Answer: font-weight
font-weight controls the boldness of text, e.g. font-weight: bold or 700.