MCQ Hive stays free thanks to ads. Please disable your ad blocker for this site so content and features keep working.
Web Development
CSS
Beginner
Q
Which selector has the highest specificity?
A.nav .item a
Bnav ul li a
Ca:hover
D#nav .item a
Correct Answer:
D. #nav .item a
Explanation:
#nav .item a scores (1,1,1). One ID outweighs any number of classes.
ALSO KNOW (related points):
• What does the selector div > p select? → elements that are direct children of a
• How many columns does the Bootstrap grid system use? → 12