CSS Basics: Easy Interview Questions Quiz — Questions & Answers

This quiz contains 15 questions. Below is a complete reference of all questions, answer choices, and correct answers. You can use this section to review after taking the interactive quiz above.

  1. Question 1: Definition of CSS

    What does CSS stand for when discussing web technologies?

    • Cascading Style Sheets
    • Creative Style Syntax
    • Computer Styled System
    • Coded Sample Sheets
    • Colorful Styling Sheets
    Show correct answer

    Correct answer: Cascading Style Sheets

  2. Question 2: Purpose of Using CSS

    Which of the following best describes the main purpose of using CSS on a webpage?

    • To manage and style the visual appearance of HTML elements
    • To write server-side scripts
    • To create database connections
    • To organize files in folders
    • To manage user authentication
    Show correct answer

    Correct answer: To manage and style the visual appearance of HTML elements

  3. Question 3: CSS Syntax Components

    In the CSS rule below, what is the role of 'h1'? Example: h1 { color: blue; }

    • Selector
    • Attribute
    • Tag
    • Property
    • Element
    Show correct answer

    Correct answer: Selector

  4. Question 4: Applying CSS to HTML

    Which of the following is NOT a way to apply CSS to an HTML page?

    • Embedded CSS
    • Inline CSS
    • External CSS
    • Internal CSS
    • Procedural CSS
    Show correct answer

    Correct answer: Procedural CSS

  5. Question 5: CSS Priority Order

    Which type of CSS rule holds the highest priority when conflicting styles are defined?

    • Inline CSS
    • External CSS
    • Internal CSS
    • Browser default CSS
    • Imported CSS
    Show correct answer

    Correct answer: Inline CSS

  6. Question 6: CSS3 Feature

    Which of the following features is introduced with CSS3 but NOT available in older CSS versions?

    • 3D transformations and animations
    • Changing text color
    • Setting background images
    • Margin and padding adjustment
    • Hiding elements
    Show correct answer

    Correct answer: 3D transformations and animations

  7. Question 7: Current CSS Version

    As of 2025, what is the latest official version of CSS?

    • CSS3
    • CSS4
    • CSS2
    • CSS5
    • CSSX
    Show correct answer

    Correct answer: CSS3

  8. Question 8: CSS Framework Examples

    Which of the following is an example of a CSS framework?

    • Bulma
    • React
    • jQuery
    • Python
    • MongoDB
    Show correct answer

    Correct answer: Bulma

  9. Question 9: CSS Reusability Advantage

    What is a key benefit of using external CSS files on multiple HTML pages?

    • A single change updates styles across all linked pages
    • It increases the size of the webpage
    • Each page must have its own separate style rules
    • Only one HTML tag can use the styles
    • Inline styles become unavailable
    Show correct answer

    Correct answer: A single change updates styles across all linked pages

  10. Question 10: Disadvantage of CSS

    Which of the following is a common disadvantage of CSS?

    • Different browsers may interpret styles differently
    • It always slows down websites
    • It encrypts all webpage text
    • It can only be written in plain text editors
    • It requires internet connection to function
    Show correct answer

    Correct answer: Different browsers may interpret styles differently

  11. Question 11: Internal CSS Identification

    Where is internal CSS placed inside an HTML document?

    • Inside the <head> section in a <style> tag
    • Inside the <body> tag next to images
    • In a separate .css file only
    • After the closing </html> tag
    • In the CSS folder under root
    Show correct answer

    Correct answer: Inside the <head> section in a <style> tag

  12. Question 12: CSS Property Example

    If you want to change the text size of all paragraphs, which property should you use? Example: p { ______: 16px; }

    • font-size
    • text-style
    • size-font
    • font-color
    • text-decoraion
    Show correct answer

    Correct answer: font-size

  13. Question 13: External CSS Linking

    How do you link an external CSS file named 'style.css' in your HTML document?

    • <link rel="stylesheet" href="style.css" />
    • <css link="style.css">
    • <stylesheet src="style.css">
    • <style type="text/css" link="style.css">
    • <script href="style.css">
    Show correct answer

    Correct answer: <link rel="stylesheet" href="style.css" />

  14. Question 14: CSS Version Compatibility

    Which statement is true about the relationship between CSS and CSS3?

    • CSS3 is backward compatible with CSS
    • CSS ignores all rules from older versions
    • CSS3 can only be used on mobile devices
    • CSS3 does not support animations
    • CSS and CSS3 are unrelated languages
    Show correct answer

    Correct answer: CSS3 is backward compatible with CSS

  15. Question 15: CSS Syntax Error Detection

    Which line has a syntax error and will NOT work as intended?

    • p { background-color: yellow; }
    • div { color: red; }
    • h2 { font-sizee: 14px; }
    • body { margin: 0; }
    • a { text-decoration: none; }
    Show correct answer

    Correct answer: h2 { font-sizee: 14px; }