1)What does CSS stand for?
- Creative Style Sheets
- Cascading Style Sheets
- Computer Style Sheets
- Custom Style Sheets
Correct answer : B
|
2)Which of the following is the correct syntax for writing a CSS rule?
- element { property: value; }
- element: property: value;
- element { property = value; }
- element property: value;
Correct answer : A
|
3)How do you apply a style to a specific element on a webpage?
- By using the element's ID attribute
- By using the element's class attribute
- By using the element's name attribute
- All of the above
Correct answer : D
|
4)What is the default value for the position property in CSS?
- absolute
- relative
- fixed
- static
Correct answer : D
|
5)How do you apply a style to all the paragraphs on a webpage?
- By using the p element as the selector
- By using the #p as the selector
- By using the .p as the selector
- None of the above
Correct answer : A
|
6)Which of the following is not a valid value for the display property in CSS?
- block
- inline
- none
- list
Correct answer : D
|
7)How do you specify a color in CSS?
- By using the color name, such as "red"
- By using the RGB value, such as "rgb(255,0,0)"
- By using the hexadecimal value, such as "#FF0000"
- All of the above
Correct answer : D
|
8)What is a CSS class?
- A group of elements that share the same style
- A specific element that has a unique style
- A type of selector that is used to apply a style to a specific element
- None of the above
Correct answer : A
|
9)How do you specify the font size in CSS?
- By using the font-size property and a number value, such as "12px"
- By using the size property and a number value, such as "12"
- By using the font property and a size value, such as "12pt"
- All of the above
Correct answer : A
|
10)What is the default value for the visibility property in CSS?
- visible
- hidden
- transparent
- None of the above
Correct answer : A
|
11)How do you create a CSS rule that only applies to a specific element when it is hovered over with the mouse?
- By using the :hover pseudo-class
- By using the hover property
- By using the mouseover property
- None of the above
Correct answer : A
|
12)Which of the following is not a valid value for the overflow property in CSS?
- visible
- hidden
- scroll
- overflow
Correct answer :D
|
13)How do you specify the background color of an element in CSS?
- By using the background-color property and a color value
- By using the bg-color property and a color value
- By using the color property and a background-color value
- None of the above
Correct answer : A
|
14)What is the default value for the float property in CSS?
- left
- right
- none
- Both a and b
Correct answer : C
|
15)How do you specify the font family of an element in CSS?
- By using the font-family property and a list of font names, such as "Arial, Helvetica, sans-serif"
- By using the font property and a list of font names, such as "Arial, Helvetica, sans-serif"
- By using the family property and a list of font names, such as "Arial, Helvetica, sans-serif"
- All of the above
Correct answer : A
|
16)What is the default value for the z-index property in CSS?
- 0
- 1
- -1
- None of the above
Correct answer : D
Default value is : auto
|
17)How do you specify the width of an element in CSS?
- By using the width property and a number value, such as "200px"
- By using the size property and a number value, such as "200"
- By using the width property and a percentage value, such as "50%"
- Both A and C
Correct answer : D
|
18)What is a CSS pseudo-class?
- A special class that is used to apply a style to a specific element
- A class that is used to apply a style to a group of elements
- A class that is used to apply a style to an element when it is in a specific state or condition
- None of the above
Correct answer : C
|
19)How do you specify the padding of an element in CSS?
- By using the padding property and a number value, such as "10px"
- By using the padding-top, padding-right, padding-bottom, and padding-left properties and a number value, such as "10px"
- By using the space property and a number value, such as "10"
- Both B and A
Correct answer : D
|
20)What is the default value for the cursor property in CSS?
- pointer
- default
- auto
- None of the above
Correct answer : C
|
21)How do you specify the margin of an element in CSS?
- By using the margin property and a number value, such as "10px"
- By using the margin-top, margin-right, margin-bottom, and margin-left properties and a number value, such as "10px"
- By using the space property and a number value, such as "10"
- Both A and B
Correct answer : D
|
22)What is the default value for the display property of a list item in CSS?
- block
- inline
- list-item
- None of the above
Correct answer : C
|
23)How do you specify the border of an element in CSS?
- By using the border property and a number value, such as "1px solid #000000"
- By using the border-top, border-right, border-bottom, and border-left properties and a number value, such as "1px solid #000000"
- By using the border property and a color value, such as "#000000"
- Both A and B
Correct answer : D
|
24)What is the default value for the position property of a list item in CSS?
- static
- relative
- absolute
- fixed
Correct answer : A
|
25)How do you specify the font style of an element in CSS?
- By using the font-style property and a value such as "italic" or "oblique"
- By using the style property and a value such as "italic" or "oblique"
- By using the font property and a value such as "italic" or "oblique"
- All of the above
Correct answer : A
|
26)What is the default value for the clear property in CSS?
- none
- left
- right
- All of the above
Correct answer : A
|
27)How do you specify the font weight of an element in CSS?
- By using the font-weight property and a value such as "bold" or "normal"
- By using the weight property and a value such as "bold" or "normal"
- By using the font property and a value such as "bold" or "normal"
- All of the above
Correct answer : A
|
28)What is the default value for the text-align property in CSS?
- left
- right
- center
- justify
Correct answer : A
|
29)How do you specify the text decoration of an element in CSS?
- By using the text-decoration property and a value such as "underline" or "overline"
- By using the decoration property and a value such as "underline" or "overline"
- By using the text property and a value such as "underline" or "overline"
- All of the above
Correct answer : A
|
30)What is the default value for the visibility property of a list item in CSS?
- visible
- hidden
- transparent
- None of the above
Correct answer : A
|
31)How do you specify the vertical alignment of an element in CSS?
- By using the vertical-align property and a value such as "top" or "bottom"
- By using the align property and a value such as "top" or "bottom"
- By using the valign property and a value such as "top" or "bottom"
- All of the above
Correct answer : A
|
32)What is the default value for the list-style-type property in CSS?
- none
- disc
- circle
- square
Correct answer : B
|
33)How do you specify the text color of an element in CSS?
- By using the text-color property and a color value
- By using the color property and a text-color value
- By using the font-color property and a color value
- None of the above
Correct answer : B
|
34)What is the default value for the list-style-position property in CSS?
- outside
- inside
- none
- Both a and b
Correct answer : A
|
35)How do you specify the text transformation of an element in CSS?
- By using the text-transform property and a value such as "uppercase" or "lowercase"
- By using the transform property and a value such as "uppercase" or "lowercase"
- By using the text property and a value such as "uppercase" or "lowercase"
- All of the above
Correct answer : A
|
36)What is the default value for the list-style-image property in CSS?
- none
- url("image.jpg")
- url("image.png")
- Both b and c
Correct answer : A
|
37)How do you specify the vertical spacing between lines of text in CSS?
- By using the line-spacing property and a number value, such as "1.5"
- By using the leading property and a number value, such as "1.5"
- By using the spacing property and a number value, such as "1.5"
- All of the above
Correct answer : A
|
38)What is the default value for the text-indent property in CSS?
- 0
- 1
- -1
- None of the above
Correct answer : A
|
39)How do you specify the horizontal spacing between characters of text in CSS?
- By using the letter-spacing property and a number value, such as "1px"
- By using the kerning property and a number value, such as "1px"
- By using the spacing property and a number value, such as "1"
- All of the above
Correct answer : A
|
40)What is the default value for the text-transform property in CSS?
- none
- uppercase
- lowercase
- capitalize
Correct answer : A
|
41)How do you specify the text shadow of an element in CSS?
- By using the text-shadow property and values for the horizontal offset, vertical offset, blur radius, and color, such as "2px 2px 5px #000000"
- By using the shadow property and values for the horizontal offset, vertical offset, blur radius, and color, such as "2px 2px 5px #000000"
- By using the text property and values for the horizontal offset, vertical offset, blur radius, and color, such as "2px 2px 5px #000000"
- All of the above
Correct answer : A
|
42)What is the default value for the text-decoration property in CSS?
- none
- underline
- overline
- line-through
Correct answer : A
|
43)How do you specify the text direction of an element in CSS?
- By using the text-direction property and a value such as "ltr" or "rtl"
- By using the direction property and a value such as "ltr" or "rtl"
- By using the text property and a value such as "ltr" or "rtl"
- All of the above
Correct answer : B
|
44)What is the default value for the text-align-last property in CSS?
- auto
- right
- center
- justify
Correct answer : A
|
45)How do you specify the word spacing of an element in CSS?
- By using the word-spacing property and a number value, such as "1px"
- By using the spacing property and a number value, such as "1"
- By using the words property and a number value, such as "1px"
- All of the above
Correct answer : A
|
46)What is the default value for the text-overflow property in CSS?
- clip
- ellipsis
- string
- None of the above
Correct answer : A
|
47)How do you specify the white space handling of an element in CSS?
- By using the white-space property and a value such as "normal" or "pre"
- By using the space property and a value such as "normal" or "pre"
- By using the white property and a value such as "normal" or "pre"
- All of the above
Correct answer : A
|
48)What is the default value for the white-space-collapse property in CSS?
- collapse
- separate
- discard
- None of the above
Correct answer : A
|
49)How do you specify the word break handling of an element in CSS?
- By using the word-break property and a value such as "normal" or "break-all"
- By using the break property and a value such as "normal" or "break-all"
- By using the word property and a value such as "normal" or "break-all"
- All of the above
Correct answer : A
|
50)What is the default value for the word-wrap property in CSS?
- normal
- break-word
- none
- Both a and b
Correct answer : A
|