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 line is missing its closing tag?
line 1: <p>Cricket is fun.</p>
line 2: <h2>Good morning!
line 3: <h3>Our school trip</h3> (a) line 1 (b) line 3 (c) line 2 - 2.💪 Which justify-content value puts boxes in the middle? (a) flex-end (b) space-between (c) center (d) flex-start
-
3.💬 Which text will NOT show on the page?
<p>Hello, world!</p>
<p>Fun facts</p>
<p>My best friend</p>
<!-- <p>Our school trip</p> --> (a) Hello, world! (b) Fun facts (c) Our school trip (d) My best friend -
4.🔠 How many headings are in this code?
<h1>Hello, world!</h1>
<h4>Hello, world!</h4>
<p>My pets</p>
<h2>The red kite</h2>
<p>Hello, world!</p> - 5.📝 What do we need to write HTML? (a) a printer (b) a paintbrush (c) a microphone (d) a plain text editor
- 6.🎨 A CSS file usually ends with which extension? (a) .png (b) .js (c) .css (d) .html
-
7.📱 The screen is 414px wide. What font-size (px) does the paragraph get?
p {
font-size: 12px;
}
@media (max-width: 1024px) {
p {
font-size: 8px;
}
} - 8.📱 Which tag helps phones show a page at the right size? (a) the viewport meta tag (b) the title tag (c) the br tag (d) the hr tag
-
9.📝 On how many lines does the browser show this paragraph?
<p>Birds sing<br>Sky is blue</p> -
10.✍️ How many declarations (property: value pairs) are in this rule?
body {
font-weight: bold;
padding: 8px;
font-style: italic;
} - 11.🔁 When does the else part run? (a) always (b) never (c) when if is true (d) when if is false
- 12.🌍 What do we call the computer that stores a website? (a) a server (b) a keyboard (c) a mouse (d) a printer
- 13.True or false: the browser asks for a web page. (a) True (b) False
- 14.True or false: console.log(5 + 2); goes in script.js. (a) True (b) False
-
15.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="fort.jpg" alt="An old fort" width="200"> (a) An old fort (b) A tiger asleep (c) fort.jpg (d) width - 16.What does text-align do? (a) makes the text bold (b) picks the font style (c) colours behind the text (d) centres a heading
-
17.✍️ What value is given to width in this rule?
.box {
font-weight: bold;
width: 300px;
font-size: 20px;
} (a) 300px (b) width (c) italic (d) red -
18.📦 How much space across (px) does this box take in all, margin included?
.box {
width: 90px;
padding: 30px;
border: 1px solid black;
margin: 0px;
} -
19.💬 How many paragraphs show on the page?
<p>My best friend</p>
<!-- <p>Good morning!</p> -->
<!-- <p>I love mangoes.</p> --> - 20.🔤 In “HTML”, what does the L stand for? (a) Line (b) Language (c) Laptop (d) Link
- 21.True or false: a web browser hosts websites online. (a) True (b) False
- 22.📝 What does <br> do? (a) makes text bold (b) adds a picture (c) starts a new line (d) makes a list
- 23.🏷️ Is <b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 24.💪 Which flexbox property picks row or column? (a) justify-content (b) display: flex (c) align-items (d) flex-direction
-
25.🌍 What is the path in this URL?
https://www.example.net/art/gallery.html (a) https (b) /news/today.html (c) /art/gallery.html (d) www.example.net - 26.📋 Which list tag goes inside ul or ol? (a) <li> (b) <ol> (c) <ul>
-
27.🔗 Where does this link open?
<a href="games.html" target="_blank">Play games</a> (a) in a new tab (b) in the same tab -
28.✍️ What value is given to margin in this rule?
p {
margin: 10px;
color: red;
width: 300px;
} (a) margin (b) bold (c) 8px (d) 10px -
29.🔗 Which words do you click on?
<a href="https://example.com">Contact us</a> (a) https://example.com (b) href (c) Visit the site (d) Contact us - 30.🔗 Which tag makes a clickable link? (a) <a> (b) <p> (c) <link> (d) <img>
-
31.📱 The screen is 414px wide. What font-size (px) does the paragraph get?
p {
font-size: 20px;
}
@media (min-width: 1024px) {
p {
font-size: 24px;
}
} - 32.🔠 How many heading levels does HTML have? (a) 4 (b) 3 (c) 6 (d) 10
-
33.📱 The screen is 1100px wide. What font-size (px) does the paragraph get?
p {
font-size: 12px;
}
@media (min-width: 480px) {
p {
font-size: 14px;
}
} - 34.Which of these goes in the body? (a) <title> (b) <ul> (c) <meta charset="utf-8"> (d) <link rel="stylesheet">
-
35.📝 How many paragraphs does this code make?
<p>My pets</p>
<h2>Good morning!</h2>
<p>I love mangoes.</p>
<p>Cricket is fun.</p>
<p>I love mangoes.</p>
<p>Good morning!</p> -
36.💬 Which text will NOT show on the page?
<!-- <p>My best friend</p> -->
<p>My pets</p>
<p>Good morning!</p> (a) Good morning! (b) My best friend (c) My pets -
37.🖌️ Where does the text sit on its line?
p {
font-size: 32px;
background-color: blue;
color: red;
text-align: left;
} (a) on the left (b) on the right (c) in the middle -
38.💪 How much empty space (px) is before the first box?
.row {
display: flex;
width: 300px;
justify-content: flex-end;
}
Inside are 4 boxes, each 60px wide (no margins). - 39.💪 Which justify-content value packs boxes at the end? (a) center (b) space-between (c) flex-start (d) flex-end
- 40.🌗 Is yellow on white easy or hard to read? (a) easy to read (b) hard to read
Answer key
- line 2
- center
- Our school trip
- 3
- a plain text editor
- .css
- 8
- the viewport meta tag
- 2
- 3
- when if is false
- a server
- True
- True
- An old fort
- centres a heading
- 300px
- 152
- 1
- Language
- False
- starts a new line
- an opening tag
- flex-direction
- /art/gallery.html
- <li>
- in a new tab
- 10px
- Contact us
- <a>
- 20
- 6
- 14
- <ul>
- 5
- My best friend
- on the left
- 60
- flex-end
- hard to read
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids