CSS Online Quiz



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 a element based on its class attribute?

A - The Type Selector

B - The Universal Selector

C - The Descendant Selector

D - The Class Selector

Answer : D

Explanation

The Class Selector matches a element based on its class attribute.

Q 3 - Which of the following defines a measurement in picas?

A - in

B - mm

C - pc

D - pt

Answer : C

Explanation

pc − Defines a measurement in picas. A pica is equivalent to 12 points; thus, there are 6 picas per inch.

Q 4 - Which of the following property is used to control the position of an image in the background?

A - background-color

B - background-image

C - background-repeat

D - background-position

Answer : D

Explanation

The background-position property is used to control the position of an image in the background.

Q 5 - Which of the following property is used to add or subtract space between the words of a sentence?

A - text-indent

B - text-align

C - text-decoration

D - text-transform

Answer : A

Explanation

The text-indent property is used to indent the text of a paragraph.

Q 6 - Which of the following property is used to capitalize text or convert text to uppercase or lowercase letters?

A - text-indent

B - text-align

C - text-decoration

D - text-transform

Answer : D

Explanation

The text-transform property is used to capitalize text or convert text to uppercase or lowercase letters.

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 style of right border?

A - :border-bottom-style

B - :border-top-style

C - :border-left-style

D - :border-right-style

Answer : D

Explanation

The border-right-style changes the style of right border.

Q 9 - Which of the following property allows you to control the shape or appearance of the marker of a list?

A - list-style-type

B - list-style-position

C - list-style-image

D - list-style

Answer : A

Explanation

The list-style-type allows you to control the shape or appearance of the marker.

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