Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

CSS CSS Foundations Advanced Selectors Pseudo-Classes: :nth-child

Robbie Thomas
Robbie Thomas
31,093 Points

Can't get past challenge #2

I know I have the code right (or at least I think I do):

li:nth-child(3) { color: white ; background-color: #FF6347; }

But it says I'm wrong.

Answers?

4 Answers

Bertan Ulusoy
Bertan Ulusoy
18,047 Points

I think, you need to add new rule (new line) and remove the color property.

Just like this.

li:nth-child(3) { background-color: #FF6347; }

Robbie Thomas
Robbie Thomas
31,093 Points

Yes, I totally done f**ked up with reading that. Keywords: Create a new rule and not modify the rule on challenge one. Bad assumption.

Thanks a bunch sir, I just past the challenge.