A Greater Selection

← Forum
307 pts

Max Giliberti

Last step of the CSS selectors. Pseudo selectors nth-child

Hello. im stuck at the last step of CSS selectors. i did pass the nth-child at the step 4.4 but now, its not working at 5.5. Here is my HTML code:

my html:

<html>
<head>
    <link type="text/css" rel="stylesheet" href="stylesheet.css"/>
    <title>Result</title>
</head>
<body>
<h3>
<p class="fancy">nota1</p>
<p class="fancy">nota2</p>
<p class="fancy">nota3</p>
<p>nota1</p>
<p>nota2</p>
<p>nota3</p>
</h3>
<p id="serious"> nota de id</p>
</body></html>

my css:
.fancy{
font-family:cursive;
color:violet;
}

#serious{
font-family:Courier;
color:#8C8C8C;
}

body:nth-child(4): {
font-size:26px;
}

Instructions says:
Add a third paragraph to the HTML document. On the CSS tab, use nth-child to give it a font size of 26px. Remember: your paragraph is the third paragraph, but the fourth CHILD of body. The h3 counts as the first child!

My Error is: Oops, try again! Did you give your third paragraph a font-size of 26px? It looks like it's currently undefined.

Anyone tell me what im missing here ? i tryed a lot of combinations. i tryed with and without space between body and :
i tryed p as a selector but didin't work too. By the way Here is the Hint: That means you'll need to use nth-child(4) to select your paragraph on the CSS tab.

If you're getting strange numbers for your font-size, type Ctrl-0 or Cmd-0 to reset your zoom!

Make sure to leave a space between body :nth-child. If you don't have a space it means "find the body tag that is an nth-child". If you have a space it means "find the nth-child of the body tag".

I almot copy paste it but still not working. Any advise ?

  • 277 pts

    Cody West

    0 votes

    You need to make each h3 and p its own line, don't nest anything.

  • 150 pts

    mcreisinger

    0 votes

    For some reason it looks for a space between body and :nth-child.

Sign in to post to the forum.

Sign in