The correct example of class selector is .
Correct answer
A. h2.type1 {color: #000000;}
13 views
A. h2.type1 {color: #000000;}
13 views
h2.type1 {color: #000000;} is the correct class selector. The dot joins the element name to the class name with no space, so the rule applies only to <h2> elements with class="type1".
A space would turn it into a descendant selector, and # denotes an ID, not a class.
Keep preparing with more Computer Science MCQs on MCQsExam.com.
Not sure why the answer is A? Ask here and get an explanation.