Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS

Mike Bronner
Mike Bronner
16,395 Points

nth-child Pseudo Class Challenge Problem

The challenge (https://teamtreehouse.com/library/pseudoclasses-nthchild) appears straight forward.

Here is my css:

li:nth-child(even)
{
  background-color: black;
}

It previews perfectly fine -- all even rows are colored black. Any idea what I might be missing? I'm sure its some semantic issue somewhere that isn't exactly how the challenge expects it.

Thanks! ~Mike

2 Answers

Mike Bronner
Mike Bronner
16,395 Points

Ugh! Nevermind ... my mind kept skipping the requirement for white text color. After reading through it 10 times I finally saw it. :) Sorry.

Wayne Priestley
Wayne Priestley
19,579 Points

Hi Mike,

Been there (more than once ) lol.