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.📱 What does a media query check? (a) the time of day (b) the battery level (c) the screen width (d) the page title
- 2.⚡ Which JavaScript word shows a pop-up box? (a) for (b) let (c) alert() (d) console.log()
-
3.📝 On how many lines does the browser show this paragraph?
<p>Rivers flow<br>Roses are red<br>Stars shine<br>Kites fly high<br>Birds sing</p> - 4.📋 Which list tag shows bullet points? (a) <ul> (b) <li> (c) <ol>
- 5.Which of these is an opening tag? (a) </h1> (b) </body> (c) <body> (d) </p>
- 6.True or false: <table> holds the whole table. (a) True (b) False
- 7.💪 Which justify-content value equal gaps, none at ends? (a) flex-end (b) flex-start (c) center (d) space-between
- 8.🖼️ Why do we add alt text to an image? (a) to make it bigger (b) to load it faster (c) to colour it (d) to describe the image
-
9.✍️ What is the selector in this CSS rule?
#top {
color: red;
padding: 8px;
font-style: italic;
background-color: yellow;
} (a) color (b) 8px (c) #top (d) li - 10.🔗 Which tag makes a clickable link? (a) <img> (b) <p> (c) <a> (d) <link>
-
11.📊 How many rows does this table have?
<table>
<tr><th>Name</th><th>Fruit</th><th>Price</th></tr>
<tr><td>Papaya</td><td>Orange</td><td>Banana</td></tr>
<tr><td>Litchi</td><td>Grapes</td><td>Papaya</td></tr>
</table> - 12.🧭 How many <main> parts should a page have? (a) three (b) ten (c) one (d) none
-
13.🎯 Which CSS selector matches this element?
<h1 class="big" id="intro">Hello</h1> (a) h1 (b) .intro (c) #big (d) h2 - 14.🌈 In #000025 the blue part is the hex number 25. What is it as a normal number?
- 15.⚡ Which JavaScript word runs code when true? (a) console.log() (b) let (c) for (d) if
- 16.✍️ How does a CSS comment start? (a) // (b) <!-- (c) # (d) /*
- 17.🧱 HTML gives a web page its ___. (a) speed (b) sound (c) colours (d) structure
-
18.💬 How many paragraphs show on the page?
<p>Good morning!</p>
<p>My pets</p>
<!-- <p>Our school trip</p> -->
<p>I love mangoes.</p>
<!-- <p>The red kite</p> --> - 19.Which of these does HTML do? (a) checks a quiz answer (b) makes a link (c) adds space around boxes (d) changes the page live
- 20.⚡ Which tag holds JavaScript in a page? (a) <style> (b) <js> (c) <script> (d) <code>
-
21.⚡ What number does this code print?
let a = 2;
let b = 2;
console.log(a * b); -
22.💪 How much empty space (px) is before the first box?
.row {
display: flex;
width: 240px;
justify-content: center;
}
Inside are 3 boxes, each 60px wide (no margins). -
23.⚡ What does this code print? (Look at the quotes!)
let x = "5";
let y = 1;
console.log(x + y); (a) 6 (b) 51 (c) Error - 24.💪 Which flexbox property turns on flexbox? (a) align-items (b) display: flex (c) gap (d) flex-direction
-
25.💬 Which text will NOT show on the page?
<p>I love mangoes.</p>
<p>Good morning!</p>
<!-- <p>Fun facts</p> -->
<p>Cricket is fun.</p> (a) Fun facts (b) I love mangoes. (c) Good morning! (d) Cricket is fun. - 26.📋 Which tag goes around each item of a list? (a) <ol> (b) <p> (c) <li> (d) <ul>
- 27.🧭 Why use <nav> instead of <div> for a menu? (a) it tells its meaning (b) it adds pictures (c) it loads faster (d) it makes text red
-
28.⚡ What number does this code print?
let a = 8;
let b = 2;
console.log(a * b); - 29.🔠 How many <h1> headings should a page usually have? (a) 3 (b) 6 (c) 1 (d) 10
- 30.What is <input type="radio"> for? (a) is for one line of words (b) lets you pick only one (c) is for an email address (d) picks a day
- 31.Which of these is not safe to do online? (a) share your OTP (b) keep passwords secret (c) ask before downloading (d) log out on shared PCs
-
32.📝 On how many lines does the browser show this paragraph?
<p>Birds sing<br>Sky is blue<br>Roses are red<br>Kites fly high<br>Rivers flow</p> - 33.🌗 Is light grey on white easy or hard to read? (a) hard to read (b) easy to read
-
34.📋 How many items does this list show?
<ul>
<li>Grapes</li>
<li>Banana</li>
<li>Jamun</li>
<li>Guava</li>
<li>Mango</li>
<li>Litchi</li>
</ul> -
35.💪 How much empty space (px) is left after the last box?
.row {
display: flex;
width: 440px;
justify-content: flex-start;
}
Inside are 4 boxes, each 100px wide (no margins). - 36.📝 What does <hr> draw? (a) a link (b) a picture (c) a line across the page (d) a table
-
37.⚡ What does this code show?
let name = "Meera";
console.log("Well done, " + name + "!"); (a) name (b) Well done, name! (c) Well done, Meera! (d) Meera -
38.🎯 Which CSS selector matches this element?
<p class="note" id="intro">Hello</p> (a) p (b) .intro (c) .big (d) #main -
39.💬 How many paragraphs show on the page?
<!-- <p>I love mangoes.</p> -->
<!-- <p>My best friend</p> -->
<p>Good morning!</p>
<p>Hello, world!</p> -
40.🔗 Where does this link open?
<a href="contact.html">Contact us</a> (a) in the same tab (b) in a new tab
Answer key
- the screen width
- alert()
- 5
- <ul>
- <body>
- True
- space-between
- to describe the image
- #top
- <a>
- 3
- one
- h1
- 37
- if
- /*
- structure
- 3
- makes a link
- <script>
- 4
- 30
- 51
- display: flex
- Fun facts
- <li>
- it tells its meaning
- 16
- 1
- lets you pick only one
- share your OTP
- 5
- hard to read
- 6
- 40
- a line across the page
- Well done, Meera!
- p
- 2
- in the same tab
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids