Check out a free preview of the full Intermediate HTML & CSS course

The "CSS Specificity Quiz" Lesson is part of the full, Intermediate HTML & CSS course featured in this preview video. Here's what you'd learn in this lesson:

Jen shares a specificity quiz that challenges students to calculate the correct specificity.

Preview
Close

Transcript from the "CSS Specificity Quiz" Lesson

[00:00:00]
>> Now we're gonna have a quiz. I know that you're very excited about this, but you can do this at your own pace and at your own time. Once again, Estelle Weil has put together a fantastic little quiz that has to do with the speciFISHity of selectors. And she, of course is the one who wrote about specificity, the cheat sheet with the plankton, the fish, and the sharks.

[00:00:21]
So here are a whole series of selectors. You can do this on your own and it will grade it for you. So for example, if I say this one here with the class of important is 001, which is incorrect, by the way. I can check my answers, and she'll say, well, you got the 0 right, [LAUGH] but you didn't get the other numbers right.

[00:00:46]
So I can switch that around to what it should be. And check my answers again. And it will go ahead and do that check for you. So, what I would encourage you to do is to take some time to go through her quiz here. They get progressive more difficult as you get down the bottom.

[00:01:07]
And see how you can generate this three digit numbers. The greater the specificity of these numbers, the more likely they are to apply in the absence of inheritance in the cascade, which are the extra special source that sometimes make things work not the way quite what you would expect.

[00:01:26]
So feel free to to get some practice calculating these numbers, it's a really great exercise and well worth doing.

Learn Straight from the Experts Who Shape the Modern Web

  • In-depth Courses
  • Industry Leading Experts
  • Learning Paths
  • Live Interactive Workshops
Get Unlimited Access Now