Test Your Knowledge - CSS Basics Quiz

Select

This quiz has 12 multiple-choice questions. Only one answer is correct for all questions.

CSS Basics Quiz


  1. CSS is used for __ .
    1. describing the structure of Web pages
    2. describing the presentation of Web pages
    3. making Web Pages interactive
    4. sending data to the server

ans: 2


  1. Which is a valid property for changing text color?
    1. font-color
    2. color
    3. text-color
    4. None of the above

ans: 2


  1. CSS is a ___.
    1. Programming Language
    2. Scripting Language
    3. Markup Language
    4. Stylesheet Language

ans: 4


  1. Which tag is used to link external stylesheets?
    1. <link>
    2. <a>
    3. <style>
    4. <meta>

ans: 1


  1. Which ruleset will be applied to all HTML elements?
    1. body { color: blue;}
    2. * { color: blue;}
    3. div { color: blue;}
    4. .container { color: blue;}

ans: 2


  1. Which tag is used to define internal stylesheet ?
    1. <link>
    2. <a>
    3. <style>
    4. <meta>

ans: 3


  1. Which CSS property is used to change text size ?
    1. font-size
    2. text-size
    3. font-family
    4. None of the above

ans: 1


  1. Which attribute is used to define inline styles?
    1. styles
    2. font
    3. style
    4. target

ans: 3


  1. Which is a valid CSS Declaration?
    1. color = 'blue'
    2. color : blue
    3. 'color' : 'blue'
    4. 'color' = 'blue'

ans: 2


  1. External Stylesheets are defined in file with ____ extension.
    1. .css
    2. .js
    3. .design
    4. None of the above

ans: 1


  1. Which attribute value should be unique in the whole document to avoid unpredictable behavior?
    1. id
    2. class
    3. style
    4. data-*

ans: 1


  1. How a comment is written in CSS?
    1. ~ This is a valid comment ~
    2. # This is a valid comment
    3. // This is a valid comment
    4. /* This is a valid comment */

ans: 4


Share and support us

Share on social media and help us reach more people