Learn Basic JavaScript by Building a Role Playing Game - Step 1

Tell us what’s happening:

there is a bug where the body and head arent siblings, please fix this

Your code so far


<!-- User Editable Region -->

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <title>RPG - Dragon Repeller</title>
    <link rel="stylesheet" href="styles.css">
    <body>
    <div id="game">

    </div>
    </body>
  </head>
</html>

<!-- User Editable Region -->

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/133.0.0.0 Safari/537.36

Challenge Information:

Learn Basic JavaScript by Building a Role Playing Game - Step 1

Yes, there is a bug in the code you wrote. You seem to have described it?

Welcome to the forum :wave:

It’s up to you to fix it!

Please provide any errors / hints / feedback you are getting. You are geting this hint:

  1. The head and body elements should be siblings.

Can you think of what this means? They should be equal or at the same level? Are they both children of the same parent?