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.📋 Which list tag is one item of a list? (a) <li> (b) <ol> (c) <ul>
- 2.True or false: <h1> has a closing tag. (a) True (b) False
-
3.✍️ How many declarations (property: value pairs) are in this rule?
p {
font-style: italic;
background-color: yellow;
} - 4.🧭 Is <span> semantic or not semantic? (a) semantic (b) not semantic
-
5.🔁 What does this code print?
let age = 10;
if (age >= 5) {
console.log("teen");
} else {
console.log("child");
} (a) teen (b) child - 6.Which of these goes in the body? (a) <meta charset="utf-8"> (b) <style> (c) <a> (d) <title>
-
7.🌍 What is the protocol in this URL?
http://learn.example.com/art/gallery.html (a) http (b) learn.example.com (c) /art/gallery.html (d) https - 8.⚡ Which JavaScript word shows a pop-up box? (a) console.log() (b) alert() (c) let (d) if
- 9.Which of these is a strong password? (a) Rain#Drop_42! (b) abcd1234 (c) riya2014 (d) 123456
- 10.True or false: <ul> has a closing tag. (a) True (b) False
-
11.🔍 One closing tag is missing. Which one?
<b>Fun facts</b>
<i>I love mangoes.</i>
<p>Cricket is fun. (a) </i> (b) </b> (c) </h2> (d) </p> - 12.🔍 Which is the odd one out? (a) changes the text size (b) sets colours and fonts (c) adds space around boxes (d) reacts to a button click
- 13.🧩 Which language puts a picture on a page? (a) CSS (b) JavaScript (c) HTML
-
14.💬 How many paragraphs show on the page?
<p>Good morning!</p>
<p>Fun facts</p>
<!-- <p>Our school trip</p> --> - 15.🧩 Which language makes headings and lists? (a) JavaScript (b) HTML (c) CSS
- 16.True or false: li is an element selector. (a) True (b) False
- 17.🔢 To build and share your first web page, what comes right after “write the HTML”? (a) publish it online (b) test in a browser (c) plan what to show (d) add CSS styles
- 18.True or false: to ask before downloading is not safe. (a) True (b) False
- 19.♿ A part of the page is under a <h2> heading. Which tag should its sub-heading use? (a) <h4> (b) <h1> (c) <h3> (d) <h6>
- 20.🌈 Which hex code is blue? (a) #000000 (b) #0000ff (c) #00ffff (d) #00ff00
- 21.🎯 How many elements on a page should have the same id? (a) 2 (b) 1 (c) any number (d) 5
-
22.💪 How much empty space (px) is left after the last box?
.row {
display: flex;
width: 200px;
justify-content: flex-start;
}
Inside are 2 boxes, each 80px wide (no margins). -
23.🔍 One closing tag is missing. Which one?
<u>Rain today
<b>I love mangoes.</b>
<h1>Fun facts</h1> (a) </b> (b) </small> (c) </h1> (d) </u> -
24.📱 The screen is 414px wide. What font-size (px) does the paragraph get?
p {
font-size: 24px;
}
@media (max-width: 1024px) {
p {
font-size: 18px;
}
} -
25.🔁 What does this code print?
let age = 36;
if (age > 39) {
console.log("teen");
} else {
console.log("child");
} (a) teen (b) child - 26.📄 Which part holds everything you see on the page? (a) the title (b) the head (c) the doctype (d) the body
- 27.🖼️ Does <img> need a closing tag? (a) Yes (b) No
-
28.📱 The screen is 540px wide. What font-size (px) does the paragraph get?
p {
font-size: 24px;
}
@media (max-width: 600px) {
p {
font-size: 22px;
}
} -
29.🌍 What is the protocol in this URL?
https://www.example.net/index.html (a) https (b) www.example.net (c) http (d) /index.html - 30.🧭 Is <div> semantic or not semantic? (a) not semantic (b) semantic
- 31.🛡️ Is it safe to use the same password on every site? (a) No (b) Yes
- 32.🔁 Which word runs code only when something is true? (a) let (b) for (c) if (d) log
-
33.🖌️ What colour is behind the letters?
h1 {
background-color: red;
color: yellow;
font-size: 36px;
text-align: left;
} (a) red (b) purple (c) yellow -
34.📝 How many <input> tags are in this form?
<form>
<input type="number">
<input type="date">
<input type="text">
<input type="email">
<input type="submit" value="Send">
</form> -
35.💬 Which text will NOT show on the page?
<p>Our school trip</p>
<p>Cricket is fun.</p>
<!-- <p>I love mangoes.</p> --> (a) Our school trip (b) Cricket is fun. (c) I love mangoes. -
36.✍️ How many declarations (property: value pairs) are in this rule?
#top {
border: 2px solid;
} - 37.📛 In <a href="x.html">, what is href? (a) an element name (b) a comment (c) an attribute (d) a closing tag
- 38.💪 Which justify-content value equal gaps, none at ends? (a) center (b) flex-start (c) flex-end (d) space-between
- 39.True or false: a code editor opens web pages for us. (a) True (b) False
- 40.True or false: <nav> holds one blog post. (a) False (b) True
Answer key
- <li>
- True
- 2
- not semantic
- teen
- <a>
- http
- alert()
- Rain#Drop_42!
- True
- </p>
- reacts to a button click
- HTML
- 2
- HTML
- True
- add CSS styles
- False
- <h3>
- #0000ff
- 1
- 40
- </u>
- 18
- child
- the body
- No
- 22
- https
- not semantic
- No
- if
- red
- 5
- I love mangoes.
- 1
- an attribute
- space-between
- False
- False
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids