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.🔒 Is the connection to this address scrambled (encrypted)?
http://www.example.net/about.html (a) Yes (b) No -
2.💪 How much empty space (px) is before the first box?
.row {
display: flex;
width: 180px;
justify-content: center;
}
Inside are 2 boxes, each 80px wide (no margins). - 3.🔠 Which heading shows the BIGGEST text: <h3>, <h4>, <h2> or <h1>? (a) <h2> (b) <h3> (c) <h1> (d) <h4>
- 4.🔠 Which heading shows the BIGGEST text: <h2>, <h6>, <h3> or <h5>? (a) <h6> (b) <h3> (c) <h2> (d) <h5>
- 5.📝 What does a password box show instead of letters? (a) dots (b) emojis (c) numbers (d) capital letters
- 6.🎯 What kind of selector is .note? (a) an id selector (b) an element selector (c) a class selector
- 7.🔠 Which heading shows the SMALLEST text: <h3>, <h6>, <h2> or <h4>? (a) <h2> (b) <h3> (c) <h4> (d) <h6>
- 8.📋 Which list tag is an unordered list? (a) <li> (b) <ul> (c) <ol>
- 9.🖌️ Which CSS property makes letters bigger? (a) text-align (b) color (c) font-size (d) font-weight
-
10.🔁 How many times does this code print “Hello”?
for (let i = 0; i <= 7; i++) {
console.log("Hello");
} - 11.True or false: the content is the line round the box. (a) False (b) True
- 12.📄 Where does <style> go: in the head or in the body? (a) in the body (b) in the head
- 13.📄 Can HTML on its own add pictures to a page? (a) No (b) Yes
- 14.📄 Which part holds everything you see on the page? (a) the title (b) the doctype (c) the head (d) the body
-
15.🖌️ Where does the text sit on its line?
p {
background-color: blue;
text-align: left;
font-size: 40px;
color: orange;
} (a) on the right (b) in the middle (c) on the left -
16.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Space Facts</title>
</head>
<body>
<h1>My drawings</h1>
<p>I like to read.</p>
</body>
</html> (a) I like to read. (b) My drawings (c) body (d) Space Facts - 17.📝 Does <hr> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
- 18.📄 Where does <link rel="stylesheet"> go: in the head or in the body? (a) in the head (b) in the body
- 19.🖼️ Which attribute of <img> is read by screen readers? (a) width (b) alt (c) height (d) src
-
20.📊 How many rows does this table have?
<table>
<tr><td>Banana</td><td>Litchi</td></tr>
<tr><td>Grapes</td><td>Banana</td></tr>
<tr><td>Papaya</td><td>Guava</td></tr>
</table> - 21.📋 Which list shows the steps of a recipe best? (a) <br> (b) <hr> (c) <ol> (d) <ul>
- 22.🚀 Which file should this code go in: alert(score); (a) script.js (b) style.css (c) index.html
- 23.True or false: .note is an element selector. (a) True (b) False
-
24.📦 How much space across (px) does this box take in all, margin included?
.box {
width: 190px;
padding: 5px;
border: 5px solid black;
margin: 10px;
} -
25.💬 Which text will NOT show on the page?
<p>The red kite</p>
<p>Fun facts</p>
<p>My pets</p>
<!-- <p>Cricket is fun.</p> --> (a) My pets (b) Fun facts (c) The red kite (d) Cricket is fun. -
26.📄 What is the big heading shown on this page?
<!DOCTYPE html>
<html>
<head>
<title>Art Gallery</title>
</head>
<body>
<h1>Match report</h1>
<p>Here is my best one.</p>
</body>
</html> (a) body (b) Here is my best one. (c) Match report (d) Art Gallery - 27.Which of these is true of a code editor? (a) answers page requests (b) stores a website’s files (c) colours code to help us (d) has an address bar
- 28.True or false: padding is space inside the border. (a) True (b) False
- 29.📊 Are <th> cells shown bold and centred by default? (a) No (b) Yes
- 30.Which of these is an opening tag? (a) </body> (b) <li> (c) </b> (d) </li>
- 31.⚖️ Which selector is the strongest? (a) an element selector (b) a class selector (c) an id selector
- 32.🖌️ Which CSS property makes the text bold? (a) font-size (b) font-weight (c) background-color (d) color
-
33.📊 How many heading cells (<th>) does this table have?
<table>
<tr><th>Name</th><th>Fruit</th><th>Price</th><th>Day</th></tr>
<tr><td>Guava</td><td>Banana</td><td>Orange</td><td>Banana</td></tr>
</table> - 34.🔡 Are HTML tag names usually written in small letters? (a) Yes (b) No
-
35.⚖️ What colour is the text of this element?
<h2 class="red" id="main">Hi</h2>
CSS:
h2 { color: yellow; }
#main { color: red; }
.red { color: white; } (a) yellow (b) red (c) purple (d) white - 36.🔗 What does HyperText mean? (a) very big text (b) secret text (c) text in colour (d) text with links
- 37.What does justify-content: flex-start do? (a) equal gaps, none at ends (b) packs boxes at the end (c) packs boxes at the start (d) puts boxes in the middle
- 38.🖼️ Does <img> need a closing tag? (a) No (b) Yes
- 39.📝 Which input type lets you pick only one? (a) radio (b) submit (c) email (d) password
-
40.🔁 What does this code print?
let marks = 25;
if (marks < 21) {
console.log("Pass");
} else {
console.log("Try again");
} (a) Try again (b) Pass
Answer key
- No
- 10
- <h1>
- <h2>
- dots
- a class selector
- <h6>
- <ul>
- font-size
- 8
- False
- in the head
- Yes
- the body
- on the left
- My drawings
- an empty tag
- in the head
- alt
- 3
- <ol>
- script.js
- False
- 230
- Cricket is fun.
- Match report
- colours code to help us
- True
- Yes
- <li>
- an id selector
- font-weight
- 4
- Yes
- red
- text with links
- packs boxes at the start
- No
- radio
- Try again
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids