CSS Online Quiz


Advertisements


Following quiz provides Multiple Choice Questions (MCQs) related to CSS. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Q 1 - Which of the following selector matches the name of any element type?

A - The Type Selector

B - The Universal Selector

C - The Descendant Selector

D - The Class Selector

Answer : B

Explanation

The Universal Selector matches the name of any element type.

Answer : D

Explanation

All of the above options are correct.

Q 4 - Which of the following property is used to set the background color of an element?

A - background-color

B - background-image

C - background-repeat

D - background-position

Answer : A

Explanation

The background-color property is used to set the background color of an element.

Q 5 - Which of the following property is used to add or subtract space between the letters that make up a word?

A - color

B - direction

C - letter-spacing

D - word-spacing

Answer : C

Explanation

The letter-spacing property is used to add or subtract space between the letters that make up a word.

Q 6 - Which of the following property is used to set the text shadow around a text?

A - white-space

B - text-shadow

C - text-decoration

D - text-transform

Answer : B

Explanation

The text-shadow property is used to set the text shadow around a text.

Q 7 - Which of the following property of a anchor element signifies an element on which the user is currently clicking?

A - :link

B - :visited

C - :hover

D - :active

Answer : D

Explanation

The :active signifies an element on which the user is currently clicking.

Q 8 - Which of the following property changes the width of bottom border?

A - :border-bottom-width

B - :border-top-width

C - :border-left-width

D - :border-right-width

Answer : A

Explanation

The border-bottom-width changes the width of bottom border.

Q 9 - Which of the following property specifies the bottom margin of an element?

A - :margin

B - :margin-bottom

C - :margin-top

D - :margin-left

Answer : B

Explanation

The margin-bottom specifies the bottom margin of an element.

Q 10 - Which of the following property specifies the left padding of an element?

A - padding-bottom

B - padding-top

C - padding-left

D - padding-right

Answer : C

Explanation

The padding-left specifies the left padding of an element.


css_questions_answers.htm

Advertisements