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.♿ Does this help everyone, or make the page harder to use: use big enough text? (a) helps everyone (b) makes it harder
-
2.🔁 How many times does this code print “Welcome”?
for (let i = 0; i < 3; i++) {
console.log("Welcome");
} - 3.⚡ Which word makes a new variable? (a) give (b) make (c) put (d) let
-
4.🔍 Which line is missing its closing tag?
line 1: <p>Our school trip
line 2: <h2>The red kite</h2>
line 3: <em>My best friend</em> (a) line 3 (b) line 2 (c) line 1 - 5.🏷️ Is <li> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
-
6.⚖️ What colour is the text of this element?
<h1 class="big" id="top">Hi</h1>
CSS:
h1 { color: yellow; }
h1 { color: blue; } (a) purple (b) red (c) blue (d) yellow - 7.🎨 Which tag holds CSS inside the head? (a) <style> (b) <script> (c) <body> (d) <css>
- 8.🎯 How many elements on a page should have the same id? (a) 1 (b) 5 (c) 2 (d) any number
-
9.🔁 What number does this code print?
let total = 0;
for (let i = 1; i <= 3; i++) {
total = total + 7;
}
console.log(total); -
10.📦 How much space across (px) does this box take in all, margin included?
.box {
width: 90px;
padding: 10px;
border: 4px solid black;
margin: 0px;
} -
11.💬 Which text will NOT show on the page?
<p>Cricket is fun.</p>
<!-- <p>The red kite</p> -->
<p>Our school trip</p> (a) The red kite (b) Our school trip (c) Cricket is fun. -
12.✍️ What is the selector in this CSS rule?
h1 {
font-weight: bold;
width: 300px;
background-color: yellow;
margin: 10px;
} (a) 300px (b) font-weight (c) h1 (d) p -
13.🔗 Which words do you click on?
<a href="contact.html">Art corner</a> (a) Art corner (b) href (c) contact.html (d) School news - 14.🔢 To build and share your first web page, which comes LAST? (a) plan what to show (b) publish it online (c) add CSS styles (d) write the HTML
-
15.💬 How many paragraphs show on the page?
<!-- <p>Good morning!</p> -->
<p>My pets</p>
<!-- <p>Rain today</p> --> - 16.🌈 What is the biggest number one colour can have in rgb()? (a) 1000 (b) 100 (c) 99 (d) 255
-
17.⚖️ What colour is the text of this element?
<h2 class="note" id="hero">Hi</h2>
CSS:
.note { color: blue; }
h2 { color: green; }
#hero { color: black; } (a) green (b) orange (c) black (d) blue - 18.📝 Which tag gives a form box a name you can click? (a) <h1> (b) <hr> (c) <label> (d) <title>
-
19.💬 How many paragraphs show on the page?
<p>Good morning!</p>
<p>Cricket is fun.</p>
<!-- <p>The red kite</p> -->
<p>I love mangoes.</p>
<p>Rain today</p> - 20.🧱 HTML gives a web page its ___. (a) structure (b) colours (c) sound (d) speed
- 21.True or false: body { margin: 0; } goes in index.html. (a) True (b) False
-
22.✍️ What is the selector in this CSS rule?
#top {
font-weight: bold;
margin: 10px;
} (a) li (b) #top (c) 10px (d) font-weight -
23.🔗 Which words do you click on?
<a href="maths.html">Contact us</a> (a) Visit the site (b) href (c) Contact us (d) maths.html -
24.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="map.png" alt="Map of India" width="200"> (a) Birthday cake (b) width (c) map.png (d) Map of India - 25.⚡ Which JavaScript word repeats code? (a) for (b) if (c) alert() (d) console.log()
- 26.🔠 Are headings shown in bold by default? (a) Yes (b) No
- 27.📊 Where do <td> cells go? (a) inside the <head> (b) inside a <li> (c) inside a <p> (d) inside a <tr>
-
28.📱 The screen is 1366px wide. What font-size (px) does the paragraph get?
p {
font-size: 16px;
}
@media (max-width: 768px) {
p {
font-size: 14px;
}
} - 29.🌈 Which colour of light is strongest in rgb(239, 129, 76)? (a) red (b) blue (c) green
- 30.🎯 Which element does the selector .big style? (a) <div class="big"> (b) <div class="red"> (c) <span class="box"> (d) <div id="big">
- 31.True or false: JavaScript counts down a timer. (a) True (b) False
- 32.True or false: a web browser colours code to help us. (a) False (b) True
- 33.Which of these is true of <nav>? (a) sits at the very top (b) holds the logo and title (c) holds the menu of links (d) holds extra side notes
-
34.💪 How much empty space (px) is before the first box?
.row {
display: flex;
width: 460px;
justify-content: flex-end;
}
Inside are 4 boxes, each 100px wide (no margins). - 35.🔤 In “HTML”, what does the L stand for? (a) Link (b) Laptop (c) Language (d) Line
- 36.📋 Which list shows the steps of a recipe best? (a) <br> (b) <ol> (c) <hr> (d) <ul>
-
37.💬 Which text will NOT show on the page?
<p>Rain today</p>
<!-- <p>Fun facts</p> -->
<p>Hello, world!</p> (a) Rain today (b) Hello, world! (c) Fun facts - 38.⚡ What does alert() show? (a) a picture (b) a pop-up box (c) a new tab (d) a table
- 39.Which of these is margin? (a) the gap round content (b) the line round the box (c) a solid or dotted edge (d) the gap to other boxes
- 40.🏷️ Every HTML tag starts with which sign? (a) ( (b) [ (c) < (d) {
Answer key
- helps everyone
- 3
- let
- line 1
- an opening tag
- blue
- <style>
- 1
- 21
- 118
- The red kite
- h1
- Art corner
- publish it online
- 1
- 255
- black
- <label>
- 4
- structure
- False
- #top
- Contact us
- Map of India
- for
- Yes
- inside a <tr>
- 16
- red
- <div class="big">
- True
- False
- holds the menu of links
- 60
- Language
- <ol>
- Fun facts
- a pop-up box
- the gap to other boxes
- <
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids