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.🔁 How many times does this code print “Hello”?
for (let i = 2; i < 11; i++) {
console.log("Hello");
} - 2.🌈 In #0000b2 the blue part is the hex number b2. What is it as a normal number?
- 3.🚀 Should file names have spaces, like my page.html? (a) No (b) Yes
-
4.🖌️ What colour are the letters?
h1 {
color: white;
background-color: purple;
text-align: left;
font-size: 28px;
} (a) purple (b) white (c) blue - 5.🔠 Which heading shows the BIGGEST text: <h4>, <h3>, <h5> or <h1>? (a) <h5> (b) <h4> (c) <h3> (d) <h1>
- 6.🌈 In #rrggbb, which colour do the first two digits give? (a) black (b) green (c) blue (d) red
- 7.📋 Which list tag lists steps in order? (a) <li> (b) <ol> (c) <ul>
- 8.What does font-size do? (a) sets the letter colour (b) picks the font style (c) makes the text bold (d) makes letters bigger
- 9.Which of these is the border? (a) space outside the border (b) the gap round content (c) a solid or dotted edge (d) space inside the border
- 10.🛡️ Online: is it safe to click prize links? (a) not safe (b) safe
- 11.🧭 Is <span> semantic or not semantic? (a) semantic (b) not semantic
- 12.🏷️ What does a closing tag have that an opening tag does not? (a) a slash / (b) a dollar $ (c) a hash # (d) a dot .
- 13.True or false: HTML rounds box corners. (a) True (b) False
-
14.📋 How many items does this list show?
<ul>
<li>Litchi</li>
<li>Orange</li>
</ul> - 15.True or false: p { color: red; } goes in style.css. (a) True (b) False
- 16.Which of these goes in the head? (a) <ul> (b) <p> (c) <h1> (d) <title>
- 17.🏷️ Is </h1> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
-
18.📱 The screen is 414px wide. What font-size (px) does the paragraph get?
p {
font-size: 24px;
}
@media (min-width: 1024px) {
p {
font-size: 32px;
}
} - 19.True or false: #logo is a class selector. (a) True (b) False
- 20.🌐 Which one colours code to help us? (a) a web server (b) a code editor (c) a web browser
-
21.🖼️ Which picture file does the browser load?
<img src="dog.jpg" alt="A happy dog" width="300"> (a) A happy dog (b) dog.jpg (c) bus.jpg (d) moon.png - 22.Which colour pair is easy to read? (a) pink on red (b) red on green (c) black on white (d) light grey on white
- 23.🛡️ Online: is it safe to check for https first? (a) not safe (b) safe
- 24.What is <input type="checkbox"> for? (a) lets you tick many (b) lets you pick only one (c) takes only numbers (d) hides what you type
- 25.True or false: HTML adds space around boxes. (a) False (b) True
- 26.🌈 Which colour of light is strongest in rgb(64, 199, 24)? (a) blue (b) red (c) green
- 27.🏷️ Which is the closing tag for <h3>? (a) <h3/> (b) <h3> (c) <\h3> (d) </h3>
- 28.True or false: a web server answers page requests. (a) False (b) True
-
29.🖌️ How big is the text, in px?
h2 {
font-size: 36px;
background-color: orange;
color: red;
text-align: right;
} - 30.📝 What does <br> do? (a) adds a picture (b) starts a new line (c) makes text bold (d) makes a list
- 31.What does justify-content: flex-end do? (a) equal gaps, none at ends (b) puts boxes in the middle (c) packs boxes at the start (d) packs boxes at the end
-
32.🌍 What is the path in this URL?
http://kids.example.org/art/gallery.html (a) http (b) /news/today.html (c) /art/gallery.html (d) kids.example.org - 33.Which of these is a strong password? (a) iloveyou (b) 111111 (c) riya2014 (d) Chai$Cup_19x
-
34.📝 How many paragraphs does this code make?
<p>Good morning!</p>
<p>Rain today</p>
<p>My best friend</p>
<h2>Rain today</h2>
<p>I love mangoes.</p>
<p>Our school trip</p> - 35.True or false: a web browser opens web pages for us. (a) True (b) False
- 36.🌈 Which hex code is cyan? (a) #ffff00 (b) #00ffff (c) #0000ff (d) #00ff00
- 37.🎯 Which element does the selector .menu style? (a) <li class="note"> (b) <li id="menu"> (c) <li class="menu"> (d) <div class="big">
- 38.Which of these is not safe to do online? (a) use a strong password (b) check for https first (c) think before you post (d) meet an online stranger
- 39.Which of these is true of a code editor? (a) is where we type code (b) turns HTML into a page (c) answers page requests (d) sends pages over the net
- 40.⚡ Which JavaScript word writes in the console? (a) console.log() (b) for (c) alert() (d) let
Answer key
- 9
- 178
- No
- white
- <h1>
- red
- <ol>
- makes letters bigger
- a solid or dotted edge
- not safe
- not semantic
- a slash /
- False
- 2
- True
- <title>
- a closing tag
- 24
- False
- a code editor
- dog.jpg
- black on white
- safe
- lets you tick many
- False
- green
- </h3>
- True
- 36
- starts a new line
- packs boxes at the end
- /art/gallery.html
- Chai$Cup_19x
- 5
- True
- #00ffff
- <li class="menu">
- meet an online stranger
- is where we type code
- console.log()
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids