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 justify-content value equal gaps, none at ends? (a) space-between (b) flex-start (c) center (d) flex-end
- 2.True or false: to post your home address is safe. (a) False (b) True
- 3.✍️ Which sign goes between a property and its value? (a) ; (b) = (c) : (d) -
-
4.🖼️ Which picture file does the browser load?
<img src="moon.png" alt="The full moon" width="150"> (a) bus.jpg (b) fort.jpg (c) The full moon (d) moon.png - 5.What is <input type="email"> for? (a) lets you pick only one (b) picks a day (c) is for an email address (d) takes only numbers
- 6.True or false: padding is the gap to other boxes. (a) False (b) True
- 7.What does justify-content: space-between do? (a) packs boxes at the start (b) puts boxes in the middle (c) packs boxes at the end (d) equal gaps, none at ends
- 8.True or false: HTML on its own can run a game loop. (a) True (b) False
-
9.🎯 Which CSS selector matches this element?
<h2 class="big" id="end">Hello</h2> (a) .end (b) .red (c) li (d) #end - 10.📄 Where does the text of <title> appear? (a) in a big heading (b) at the bottom (c) nowhere (d) on the browser tab
- 11.🎯 Which element does the selector #logo style? (a) <span class="menu"> (b) <div class="logo"> (c) <div id="end"> (d) <div id="logo">
-
12.📝 On how many lines does the browser show this paragraph?
<p>Rivers flow<br>Roses are red<br>Kites fly high<br>Stars shine<br>Sky is blue</p> - 13.📝 Does <b> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
- 14.🌍 What do we call the computer that stores a website? (a) a mouse (b) a keyboard (c) a printer (d) a server
- 15.True or false: to ask before downloading is safe. (a) False (b) True
- 16.📄 What is the first line of an HTML5 page? (a) <head> (b) <!DOCTYPE html> (c) <body> (d) <html>
-
17.✍️ How many declarations (property: value pairs) are in this rule?
.box {
color: red;
} - 18.Which colour pair is hard to read? (a) white on dark blue (b) dark grey on white (c) yellow on black (d) red on green
- 19.🔢 In a basic web page file, which comes first: “<head>” or “</body>”? (a) </body> (b) <head>
- 20.🖼️ Why do we add alt text to an image? (a) to colour it (b) to describe the image (c) to load it faster (d) to make it bigger
- 21.📄 Can HTML on its own run a game loop? (a) No (b) Yes
- 22.🛡️ Should you share your password with your best friend? (a) No (b) Yes
- 23.Which of these goes in the body? (a) <title> (b) <meta charset="utf-8"> (c) <p> (d) <link rel="stylesheet">
-
24.🔠 How many headings are in this code?
<h1>Hello, world!</h1>
<h2>My best friend</h2>
<p>Rain today</p>
<p>Fun facts</p> -
25.🌍 What is the path in this URL?
https://www.example.com/index.html (a) www.example.com (b) /art/gallery.html (c) /index.html (d) https - 26.🔍 Which is the odd one out? (a) stores a website’s files (b) shows line numbers (c) colours code to help us (d) saves our .html files
-
27.🖌️ How big is the text, in px?
h1 {
text-align: right;
font-size: 20px;
color: blue;
background-color: yellow;
} -
28.📱 The screen is 700px wide. What font-size (px) does the paragraph get?
p {
font-size: 20px;
}
@media (max-width: 480px) {
p {
font-size: 14px;
}
} -
29.🔁 What does this code print?
let marks = 25;
if (marks < 15) {
console.log("Pass");
} else {
console.log("Try again");
} (a) Pass (b) Try again -
30.🖌️ What colour are the letters?
h1 {
font-size: 12px;
text-align: left;
color: yellow;
background-color: red;
} (a) yellow (b) blue (c) red - 31.📝 Which input type sends the form? (a) radio (b) submit (c) text (d) date
- 32.True or false: to log out on shared PCs is safe. (a) False (b) True
- 33.💪 Which justify-content value packs boxes at the start? (a) flex-end (b) center (c) space-between (d) flex-start
- 34.True or false: in <img>, alt names the picture file. (a) True (b) False
- 35.Which of these is true of a web server? (a) opens web pages for us (b) sends pages over the net (c) shows pages from the web (d) has an address bar
- 36.🎨 A CSS file usually ends with which extension? (a) .png (b) .js (c) .css (d) .html
-
37.⚖️ What colour is the text of this element?
<p class="big" id="end">Hi</p>
CSS:
#end { color: blue; }
#end { color: green; } (a) green (b) yellow (c) blue (d) purple -
38.🔍 Which line is missing its closing tag?
line 1: <h2>Fun facts
line 2: <strong>Rain today</strong>
line 3: <small>My pets</small> (a) line 2 (b) line 3 (c) line 1 -
39.📝 How many paragraphs does this code make?
<p>Cricket is fun.</p>
<p>Cricket is fun.</p>
<p>My pets</p> -
40.🖼️ Which picture file does the browser load?
<img src="fort.jpg" alt="An old fort" width="400"> (a) tiger.jpg (b) An old fort (c) fort.jpg (d) kite.png
Answer key
- space-between
- False
- :
- moon.png
- is for an email address
- False
- equal gaps, none at ends
- False
- #end
- on the browser tab
- <div id="logo">
- 5
- has a closing tag
- a server
- True
- <!DOCTYPE html>
- 1
- red on green
- <head>
- to describe the image
- No
- No
- <p>
- 2
- /index.html
- stores a website’s files
- 20
- 20
- Try again
- yellow
- submit
- True
- flex-start
- False
- sends pages over the net
- .css
- green
- line 1
- 3
- fort.jpg
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids