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 trialTim Harris
4,194 PointsCSS Question: How do I set the color of paragraphs to black using a hexadecimal value.
This is one of the quiz questions that I cannot find a way to properly write.
6 Answers
Dustin Matlock
33,856 PointsHi Tim, hexadecimal colors start with #
at the beginning. The shorthand value for black is 000
.
So to select paragraphs, you want to use the p
selector, and of course the css color
property.
p {
color: #000;
}
Ken Alger
Treehouse TeacherTim:
Welcome to Treehouse!
Have you tried
p {
color: #000000;
}
Post back with questions.
Ken
Ken Alger
Treehouse TeacherTim;
Dustin shows the shorthand of black (#000
) below. Either is valid.
Ken
Tim Harris
4,194 PointsThanks much! I was trying to make this complicated when it was simple.
Ibrahima Ciss
8,507 Points#000
means 0 for Red, 0 for Green and 0 for Blue, black is not a colour, it's an absence of colour :)
Edwin Muswere
9,061 Pointsp{ color:#000 }
Sean Lopez
6,783 PointsGot it. Thanks