CSS MCQ Questions And Answers - Selectors

This section focuses on "Selectors" in Cascading Style Sheets (CSS). These Multiple Choice Questions (MCQ) should be practiced to improve the Cascading Style Sheets (CSS) skills required for various interviews (campus interviews, walk-in interviews, company interviews), placements, entrance exams and other competitive examinations.

1. How many different types of selectors in CSS?

A. 3
B. 4
C. 5
D. 6

View Answer


2. ___________ selects the HTML element by name.

A. element selector
B. Class Selector
C. Universal Selector
D. Group Selector

View Answer


3. An id is not always unique within the page so it is chosen to select a single, unique element.

A. TRUE
B. FALSE
C. Can be true or false
D. Can not say

View Answer


4. Id written with the ?

A. .
B. $
C. @
D. #

View Answer


5. Class name can be started with a number?

A. Yes
B. No
C. Depends on class
D. Depends on element

View Answer


6. The universal selector is used as a ?

A. Wildcard Character
B. Page Character
C. Commas character
D. None of the above

View Answer


7. ___________ are used to separate each selector in grouping.

A. #
B. .
C. ,
D. :

View Answer


8. A similar rule called the ____________ is specified using the plus sign (+) and is used to select elements that would be siblings of each other.

A. class selectors
B. adjacent-sibling selector
C. attribute selectors
D. None of the above

View Answer


9. Which of the following selectors selects adjacent siblings?

A. E > F
B. E < F
C. E + F
D. E - F

View Answer


10. Which of the following selectors selects direct descendents?

A. E > F
B. E < F
C. E + F
D. E - F

View Answer





Discussion


* You must be logged in to add comment.