Web Development Worksheet: Final Test
Code tip (Read it like a browser): Find the topic: HTML, CSS, JavaScript or how the web works. Read the code line by line, the way a browser would. For sums and loops, write each step down and check it again.
NameDateTime takenScore ___ / 40
- 1.True or false: <img src="cat.png"> goes in style.css. (a) True (b) False
- 2.🛡️ Online: is it safe to use a strong password? (a) not safe (b) safe
- 3.🌐 Which one saves our .html files? (a) a web server (b) a web browser (c) a code editor
- 4.🌈 Which colour is rgb(255, 0, 0)? (a) red (b) magenta (c) blue (d) black
- 5.🧩 Which language changes the text size? (a) HTML (b) CSS (c) JavaScript
- 6.🔒 What does the lock (HTTPS) in the address bar mean? (a) the site is fast (b) the site is free (c) the data is scrambled (d) the site is a game
-
7.🔠 How many headings are in this code?
<h1>Good morning!</h1>
<h3>Hello, world!</h3>
<h2>Cricket is fun.</h2>
<p>Fun facts</p>
<h2>Fun facts</h2> -
8.🔍 Which line is missing its closing tag?
line 1: <u>Cricket is fun.</u>
line 2: <h3>My pets</h3>
line 3: <em>I love mangoes. (a) line 2 (b) line 1 (c) line 3 - 9.🔠 Which heading shows the BIGGEST text: <h4>, <h2>, <h3> or <h6>? (a) <h2> (b) <h3> (c) <h4> (d) <h6>
-
10.⚡ What does this code print? (Look at the quotes!)
let x = "5";
let y = 6;
console.log(x + y); (a) Error (b) 11 (c) 56 - 11.🌍 Which one sends the page back? (a) the URL (b) the browser (c) HTTPS (d) the server
- 12.🚀 Which file should this code go in: body { margin: 0; } (a) style.css (b) index.html (c) script.js
- 13.🎨 Which tag connects an outside CSS file? (a) <css> (b) <link> (c) <a> (d) <img>
- 14.🔠 Which heading shows the BIGGEST text: <h6>, <h3>, <h4> or <h1>? (a) <h6> (b) <h4> (c) <h1> (d) <h3>
- 15.🏷️ Is </h1> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
- 16.True or false: “skipping heading levels” helps everyone use the page. (a) True (b) False
- 17.♿ A part of the page is under a <h2> heading. Which tag should its sub-heading use? (a) <h3> (b) <h5> (c) <h2> (d) <h1>
-
18.🔁 What does this code print?
let score = 26;
if (score > 42) {
console.log("You win");
} else {
console.log("Play again");
} (a) You win (b) Play again - 19.🌈 Which colour is #00ffff? (a) bright green (b) cyan (c) red (d) blue
- 20.🌈 Which colour is rgb(0, 0, 255)? (a) blue (b) bright green (c) yellow (d) white
- 21.📋 Which list suits a shopping list in any order? (a) <hr> (b) <br> (c) <ol> (d) <ul>
- 22.✍️ CSS declarations go inside which brackets? (a) { } (b) < > (c) ( ) (d) [ ]
-
23.🔁 What is the LAST number this code prints?
for (let i = 0; i < 15; i = i + 4) {
console.log(i);
} - 24.🔠 Which heading shows the BIGGEST text: <h5>, <h6>, <h1> or <h4>? (a) <h5> (b) <h6> (c) <h1> (d) <h4>
- 25.💬 Can anyone read your comments by viewing the page source? (a) No (b) Yes
-
26.⚡ What does this code show?
let name = "Arjun";
console.log("Welcome, " + name + "!"); (a) Welcome, name! (b) Arjun (c) Welcome, Arjun! (d) name -
27.⚡ What does this code show?
let name = "Arjun";
alert("Hello, " + name + "!"); (a) Hello, Arjun! (b) Hello, name! (c) name (d) Arjun - 28.📊 Which tag gives the table a title? (a) <table> (b) <caption> (c) <tr> (d) <td>
- 29.Which of these is an empty tag? (a) <img> (b) <ul> (c) <title> (d) <h1>
-
30.⚡ What does this code show?
let name = "Zoya";
console.log("Hello, " + name + "!"); (a) Hello, Zoya! (b) Zoya (c) Hello, name! (d) name -
31.🖌️ What colour is behind the letters?
h1 {
font-size: 12px;
color: white;
background-color: black;
text-align: left;
} (a) orange (b) white (c) black -
32.💪 How much empty space (px) is before the first box?
.row {
display: flex;
width: 110px;
justify-content: flex-end;
}
Inside are 2 boxes, each 50px wide (no margins). - 33.Which of these is true of <main>? (a) sits at the very top (b) holds a side box of tips (c) holds the logo and title (d) holds the main content
- 34.🌗 Is blue on purple easy or hard to read? (a) easy to read (b) hard to read
- 35.📄 Which part holds everything you see on the page? (a) the head (b) the title (c) the doctype (d) the body
- 36.🏷️ HTML marks up text using ___. (a) wires (b) tags (c) keys (d) pixels
- 37.True or false: <meta charset="utf-8"> goes in the body. (a) False (b) True
- 38.🖌️ Which CSS property sets the letter colour? (a) text-align (b) background-color (c) color (d) font-family
-
39.📋 Does this list show bullets or numbers?
<ul>
<li>Guava</li>
<li>Litchi</li>
<li>Banana</li>
</ul> (a) numbers (b) bullets - 40.🧭 Which semantic tag holds the main content? (a) <footer> (b) <header> (c) <main> (d) <article>
Answer key
- False
- safe
- a code editor
- red
- CSS
- the data is scrambled
- 4
- line 3
- <h2>
- 56
- the server
- style.css
- <link>
- <h1>
- a closing tag
- False
- <h3>
- Play again
- cyan
- blue
- <ul>
- { }
- 12
- <h1>
- Yes
- Welcome, Arjun!
- Hello, Arjun!
- <caption>
- <img>
- Hello, Zoya!
- black
- 10
- holds the main content
- hard to read
- the body
- tags
- False
- color
- bullets
- <main>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids