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.🌈 In #00002f the blue part is the hex number 2f. What is it as a normal number?
-
2.🔒 Is the connection to this address scrambled (encrypted)?
https://www.example.com/about.html (a) Yes (b) No -
3.📱 The screen is 540px wide. What font-size (px) does the paragraph get?
p {
font-size: 16px;
}
@media (min-width: 768px) {
p {
font-size: 24px;
}
} - 4.🧱 HTML gives a web page its ___. (a) speed (b) colours (c) structure (d) sound
-
5.📱 The screen is 375px wide. Does the rule inside @media apply?
p {
font-size: 16px;
}
@media (max-width: 600px) {
p {
font-size: 14px;
}
} (a) Yes (b) No -
6.🔁 What does this code print?
let age = 46;
if (age > 7) {
console.log("teen");
} else {
console.log("child");
} (a) teen (b) child - 7.True or false: <li> is an ordered list. (a) False (b) True
- 8.True or false: to meet an online stranger is not safe. (a) False (b) True
- 9.🎯 Which element does the selector li style? (a) <div> (b) <p id="hero"> (c) <span class="star"> (d) <li class="star">
- 10.📝 Which input type lets you tick many? (a) radio (b) date (c) submit (d) checkbox
- 11.Which of these is an empty tag? (a) <b> (b) <li> (c) <p> (d) <input>
- 12.🔢 When you open a web page, what comes right after “you type the URL”? (a) DNS finds the server (b) the browser shows it (c) the browser asks it (d) the server sends files
- 13.🌈 Hex digits go 0 to 9, then A to which letter? (a) G (b) F (c) J (d) Z
- 14.⚖️ Which selector is the strongest? (a) a class selector (b) an element selector (c) an id selector
-
15.🔁 What does this code print?
let score = 48;
if (score < 34) {
console.log("You win");
} else {
console.log("Play again");
} (a) Play again (b) You win -
16.🖼️ Which picture file does the browser load?
<img src="kite.png" alt="A red kite" width="350"> (a) A red kite (b) cake.jpg (c) map.png (d) kite.png - 17.Which of these is an opening tag? (a) </title> (b) </p> (c) <b> (d) </body>
- 18.🧭 Is <div> semantic or not semantic? (a) not semantic (b) semantic
-
19.🖌️ What colour is behind the letters?
h1 {
color: blue;
background-color: black;
text-align: right;
font-size: 12px;
} (a) red (b) blue (c) black - 20.🔠 Which heading shows the SMALLEST text: <h4>, <h3>, <h5> or <h6>? (a) <h4> (b) <h6> (c) <h3> (d) <h5>
-
21.🔁 What number does this code print?
let total = 0;
for (let i = 1; i <= 3; i++) {
total = total + i;
}
console.log(total); -
22.🖌️ What colour are the letters?
h1 {
font-size: 20px;
text-align: left;
background-color: blue;
color: purple;
} (a) blue (b) orange (c) purple -
23.💬 Which text will NOT show on the page?
<p>My pets</p>
<p>Fun facts</p>
<p>I love mangoes.</p>
<!-- <p>Hello, world!</p> --> (a) Hello, world! (b) My pets (c) I love mangoes. (d) Fun facts -
24.💬 Which text will NOT show on the page?
<!-- <p>Our school trip</p> -->
<p>I love mangoes.</p>
<p>Good morning!</p>
<p>Cricket is fun.</p> (a) Good morning! (b) Our school trip (c) I love mangoes. (d) Cricket is fun. - 25.True or false: <input type="text"> lets you pick only one. (a) True (b) False
- 26.🔗 What does target="_blank" do to a link? (a) hides the link (b) makes it bold (c) opens it in a new tab (d) makes it blank
- 27.⚖️ Which selector is the weakest? (a) a class selector (b) an element selector (c) an id selector
-
28.⚡ What number does this code print?
let a = 12;
let b = 10;
console.log(a * b); -
29.📝 How many paragraphs does this code make?
<p>Fun facts</p>
<p>Rain today</p>
<p>Rain today</p>
<p>Hello, world!</p>
<p>I love mangoes.</p>
<p>Fun facts</p> - 30.True or false: <h1>My Site</h1> goes in index.html. (a) True (b) False
- 31.⚡ Which JavaScript word makes a new variable? (a) let (b) for (c) if (d) alert()
- 32.True or false: .menu is a class selector. (a) False (b) True
- 33.🛡️ Is it safe to use the same password on every site? (a) No (b) Yes
-
34.🔠 How many headings are in this code?
<h1>Hello, world!</h1>
<h2>Fun facts</h2>
<p>Our school trip</p>
<p>Hello, world!</p>
<p>The red kite</p> - 35.📋 Which list suits a shopping list in any order? (a) <ul> (b) <hr> (c) <ol> (d) <br>
- 36.📋 Which list tag is an ordered list? (a) <li> (b) <ul> (c) <ol>
-
37.🖌️ What colour is behind the letters?
h2 {
font-size: 32px;
background-color: red;
text-align: right;
color: yellow;
} (a) red (b) yellow (c) black -
38.⚖️ What colour is the text of this element?
<h1 class="big" id="intro">Hi</h1>
CSS:
.big { color: green; }
.big { color: red; } (a) white (b) green (c) purple (d) red - 39.⚡ Which JavaScript word writes in the console? (a) for (b) let (c) console.log() (d) if
- 40.🔒 What does the lock (HTTPS) in the address bar mean? (a) the site is a game (b) the site is free (c) the data is scrambled (d) the site is fast
Answer key
- 47
- Yes
- 16
- structure
- Yes
- teen
- False
- True
- <li class="star">
- checkbox
- <input>
- DNS finds the server
- F
- an id selector
- Play again
- kite.png
- <b>
- not semantic
- black
- <h6>
- 6
- purple
- Hello, world!
- Our school trip
- False
- opens it in a new tab
- an element selector
- 120
- 6
- True
- let
- True
- No
- 2
- <ul>
- <ol>
- red
- red
- console.log()
- the data is scrambled
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids