CSS Mock Test


Advertisements

This section presents you various set of Mock Tests related to CSS. You can download these sample mock tests at your local machine and solve offline at your convenience. Every mock test is supplied with a mock test key to let you verify the final score and grade yourself.

Questions and Answers

CSS Mock Test II

Q 1 - Which of the following defines 1% of viewport width?

A - px

B - vh

C - vw

D - vmin

Answer : C

Explanation

vw − 1% of viewport width.

Q 2 - Which of the following uses 1vw or 1vh, whichever is smaller?

A - px

B - vh

C - vw

D - vmin

Answer : D

Explanation

vmin − 1vw or 1vh, whichever is smaller.

Answer : D

Explanation

All of the above options are correct.

Answer : D

Explanation

All of the above options are correct.

Answer : D

Explanation

All of the above options are correct.

Q 7 - 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 8 - Which of the following property is used to set the background image of an element?

A - background-color

B - background-image

C - background-repeat

D - background-position

Answer : B

Explanation

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

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

A - background-color

B - background-image

C - background-repeat

D - background-position

Answer : C

Explanation

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

Q 10 - 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 11 - Which of the following property is used to control the scrolling of an image in the background?

A - background-attachment

B - background

C - background-repeat

D - background-position

Answer : A

Explanation

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

Q 12 - Which of the following property is used as a shorthand to specify a number of other background properties?

A - background-attachment

B - background

C - background-repeat

D - background-position

Answer : B

Explanation

The background property is used as a shorthand to specify a number of other background properties.

Q 13 - Which of the following property is used to change the face of a font?

A - font-family

B - font-style

C - font-variant

D - font-weight

Answer : A

Explanation

The font-family property is used to change the face of a font.

Q 14 - Which of the following property is used to make a font italic or oblique?

A - font-family

B - font-style

C - font-variant

D - font-weight

Answer : B

Explanation

The font-style property is used to make a font italic or oblique.

Q 15 - Which of the following property is used to create a small-caps effect?

A - font-family

B - font-style

C - font-variant

D - font-weight

Answer : C

Explanation

The font-variant property is used to create a small-caps effect.

Q 16 - Which of the following property is used to increase or decrease how bold or light a font appears?

A - font-family

B - font-style

C - font-variant

D - font-weight

Answer : D

Explanation

The font-weight property is used to increase or decrease how bold or light a font appears.

Q 17 - Which of the following property is used to increase or decrease the size of a font?

A - font-size

B - font

C - font-variant

D - font-weight

Answer : A

Explanation

The font-size property is used to increase or decrease the size of a font.

Q 18 - Which of the following property is used as shorthand to specify a number of other font properties?

A - font-size

B - font

C - font-variant

D - font-weight

Answer : B

Explanation

The font property is used as shorthand to specify a number of other font properties.

Q 19 - Which of the following property is used to set the color of a text?

A - color

B - direction

C - letter-spacing

D - word-spacing

Answer : A

Explanation

The color property is used to set the color of a text.

Q 20 - Which of the following property is used to set the text direction?

A - color

B - direction

C - letter-spacing

D - word-spacing

Answer : B

Explanation

The direction property is used to set the text direction.

Q 21 - 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 22 - Which of the following property is used to add or subtract space between the words of a sentence?

A - color

B - direction

C - letter-spacing

D - word-spacing

Answer : D

Explanation

The word-spacing property is used to add or subtract space between the words of a sentence.

Q 23 - 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 24 - Which of the following property is used to align the text of a document?

A - text-indent

B - text-align

C - text-decoration

D - text-transform

Answer : B

Explanation

The text-align property is used to align the text of a document.

Q 25 - Which of the following property is used to underline, overline, and strikethrough text?

A - text-indent

B - text-align

C - text-decoration

D - text-transform

Answer : C

Explanation

The text-decoration property is used to underline, overline, and strikethrough text.

Answer Sheet

Question Number Answer Key
1 C
2 D
3 D
4 D
5 D
6 D
7 A
8 B
9 C
10 D
11 A
12 B
13 A
14 B
15 C
16 D
17 A
18 B
19 A
20 B
21 C
22 D
23 A
24 B
25 C
css_questions_answers.htm
Advertisements