1
The CSS syntax to make each word of a sentence start with a capital letter .
A.
B.
C.
D.
Answer & Solution
The
text-transform: capitalize; property in CSS capitalizes the first letter of
each word in a text element. Example: element
{ text-transform: capitalize; }.
2
The correct CSS syntax to select all paragraph elements in a div element .
A.
B.
C.
D.
Answer & Solution
To
select all <p> elements within a <div> element, the correct syntax is div p.
This is a descendant selector, which means it selects all <p> elements that are inside a <div>, regardless of how deeply nested they are.
3
The correct syntax to select the p siblings of a div element .
A.
B.
C.
D.
Answer & Solution
The
~
(tilde) selector in CSS is used to select all sibling elements that come after
a specified element. The syntax div
~ p
selects all <p> elements that are siblings of a <div> element, meaning they are on the same level in
the document tree.
4
The CSS property used to draw a line around the elements outside the border .
A.
B.
C.
D.
Answer & Solution
The
outline property in CSS is used to draw a line outside
the border of an element. It is similar to border
but doesn't affect the layout or position of elements. Example: element { outline: 2px solid red; }.
5
The CSS property used to add shadows to the text .
A.
B.
C.
D.
Answer & Solution
The
text-shadow property is used in CSS to add a shadow effect
to text. It allows you to specify the horizontal and vertical offsets, blur
radius, and color of the shadow. Example: element { text-shadow: 2px 2px 4px #000000; }.
6
All of the following is a value of the font-variant property in CSS except .
A.
B.
C.
D.
Answer & Solution
The
font-variant property controls the use of alternate glyphs
in fonts, such as small-caps or normal. Valid values are normal, small-caps, etc. "Large-caps" is not a valid
value for font-variant.
7
The CSS property used to specify whether the table cells share the common or separate border .
A.
B.
C.
D.
Answer & Solution
The
border-collapse property in CSS is used with tables to define
whether the table's borders should collapse into a single border (collapse) or be separated (separate). Example: table { border-collapse: collapse; }.
8
The CSS property used to make the rounded borders, or rounded corners around an element is _______ .
A.
B.
C.
D.
Answer & Solution
The border-radius property is used to round the corners of an element. You can specify the radius for each corner or apply a single value for all corners. Example: element { border-radius: 10px; }.
9
The CSS property used to create distance between the borders of the adjacent cells in the table is .
A.
B.
C.
D.
Answer & Solution
The
border-spacing property in CSS is used to set the distance
between the borders of adjacent cells in a table. Example: table { border-spacing: 5px; }.
10
The selector in CSS used to select the elements that do not match the selectors is .
A.
B.
C.
D.
Answer & Solution
The
:not
pseudo-class in CSS selects elements that do not match a given selector. It is
useful for excluding specific elements from being styled. Example: div:not(.class-name) { color: red; }.
