Review Questions
- A collection of questions designed to summarize and reinforce your understanding of the topic. These questions help you assess your overall grasp of the material.
Review Questions: CSS Basics
-
What does CSS stand for, and what is its primary purpose in web development?
Answer: Cascading Style Sheets; it is used to style and layout web pages.
- What is the difference between inline, internal, and external CSS?
Answer:
- Inline CSS: Applied directly to an HTML element using the
style
attribute.
- Internal CSS: Defined within a
<style>
tag in the <head>
section of an HTML document.
- External CSS: Written in a separate
.css
file and linked to the HTML document using the <link>
tag.
- How do you apply a CSS class to an HTML element?
Answer: Use the class
attribute in the HTML element and define the class in the CSS file with a .
prefix.
Example:
```html
This is a paragraph.
- What is the difference between inline, internal, and external CSS? Give one example of each.
⭐️ CSS Contents
Learn the basics of CSS, including selectors, properties, and the box model.