Technical Documentation project

I’m having trouble with my code passing due to these three instructions:

You should have at least 10 p elements (total) within your .main-section elements.
You should have at least five code elements that are descendants of .main-section elements.
You should have at least five li elements that are descendants of .main-section elements.

However, my code does in fact include these elements and I am very confused as to why this isn’t passing:

<body><main id="main-doc">
<section class="main-section" id="Java"><header>Java</header></section>
  <p></p>
  <p></p>
    <code></code>
    <code></code>
    <li></li>
    <li></li>
<section class="main-section" id="Hello_World"><header>Hello World</header></section>
  <p></p>
  <p></p>
    <code></code>
    <code></code>
    <li></li>
    <li></li>
<section class="main-section" id="Variables"><header>Variables</header></section>
  <p></p>
  <p></p>
    <code></code>
    <code></code>
    <li></li>
    <li></li>
<section class="main-section" id="Data"><header>Data</header></section>
  <p></p>
  <p></p>
    <code></code>
    <code></code>
    <li></li>
    <li></li>
<section class="main-section" id="Functions"><header>Functions</header></section>
  <p></p>
  <p></p>
    <code></code>
    <code></code>
    <li></li>
    <li></li>

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Firefox/102.0

Challenge:

You can’t just add li elements like that. They need to be inside a list.

Your section elements are ending almost as soon as they are beginning so the content below them isn’t actually in the section.

okay! we know how purposely vague the instructions are on these projects lol

so i’ll need a ul element around my li elements?

and my /section should go after p, code, and li elements?

I’m not sure this is an issue of the instructions being vague.

The rules of HTML are that you can only use list items inside of a list element. I think the instructions just assumed you would know that.

And yes, if you want elements to be inside a section, then they need to be between the opening and closing section tags. Again, I think this is something the instructions assumed you would know.

was trying to add humor to my struggle with the vague comment but oh well.

Thank you for the help! It worked!

My apologies. It is sometimes hard to tell.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.