Created
September 16, 2025 18:10
-
-
Save susanBuck/c6d044ece27b3af8d4915a7b54b6381e to your computer and use it in GitHub Desktop.
Week 3 Task Set Tips
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Select the elements on the page we will alter | |
| let num1Span = document.getElementById('num1'); | |
| let num2Span = document.getElementById('num2'); | |
| // Example numbers | |
| let num1 = 5; | |
| let num2 = 9; | |
| // Update the elements on the page with the example numbers | |
| num1Span.innerHTML = num1; | |
| num2Span.innerHTML = num2; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Demo</title> | |
| <link href=data:, rel=icon> | |
| <script src='app.js' defer></script> | |
| </head> | |
| <body> | |
| <h1>Demo</h1> | |
| <p> | |
| What is <span id='num1'></span> + <span id='num2'></span>? | |
| </p> | |
| </body> | |
| </html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment