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 of these is a weak password? (a) Chai$Cup_19x (b) iloveyou (c) Blue@Tiger_74 (d) Rain#Drop_42!
-
2.🌍 What is the protocol in this URL?
https://www.example.com/maths/tables.html (a) https (b) www.example.com (c) http (d) /maths/tables.html -
3.⚡ What does this code print? (Look at the quotes!)
let x = "1";
let y = 7;
console.log(x + y); (a) 17 (b) 8 (c) Error - 4.🔢 On a typical page, from top to bottom, which comes FIRST? (a) <header> (b) <main> (c) <footer> (d) <nav>
- 5.🖼️ Which attribute of <img> describes the picture? (a) width (b) src (c) height (d) alt
- 6.🏷️ Is <b> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
- 7.Which colour pair is easy to read? (a) pink on red (b) yellow on white (c) blue on purple (d) white on black
-
8.📦 How wide (px) is this box from the outer edge of its left border to the outer edge of its right border?
.box {
width: 140px;
padding: 30px;
border: 5px solid black;
margin: 0px;
} -
9.💬 Which text will NOT show on the page?
<p>I love mangoes.</p>
<!-- <p>Our school trip</p> -->
<p>Cricket is fun.</p> (a) Cricket is fun. (b) Our school trip (c) I love mangoes. -
10.📦 How wide (px) is this box from the outer edge of its left border to the outer edge of its right border?
.box {
width: 230px;
padding: 5px;
border: 1px solid black;
margin: 20px;
} - 11.🎯 What kind of selector is li? (a) an id selector (b) an element selector (c) a class selector
-
12.🔗 Which address opens when you click this link?
<a href="about.html">Play games</a> (a) about.html (b) https://example.com (c) contact.html (d) Play games - 13.🎯 Which element does the selector #hero style? (a) <div id="top"> (b) <div id="hero"> (c) <div class="hero"> (d) <span class="big">
-
14.🌍 What is the path in this URL?
http://www.example.com/art/gallery.html (a) /art/gallery.html (b) http (c) /news/today.html (d) www.example.com -
15.✍️ What value is given to text-align in this rule?
.box {
text-align: center;
font-style: italic;
} (a) center (b) text-align (c) 10px (d) yellow - 16.🏷️ Every HTML tag starts with which sign? (a) ( (b) < (c) [ (d) {
- 17.📱 What does a media query check? (a) the battery level (b) the page title (c) the time of day (d) the screen width
-
18.🔁 What does this code print?
let score = 2;
if (score > 43) {
console.log("You win");
} else {
console.log("Play again");
} (a) You win (b) Play again - 19.💪 Which justify-content value equal gaps, none at ends? (a) center (b) flex-end (c) space-between (d) flex-start
-
20.📊 How many heading cells (<th>) does this table have?
<table>
<tr><th>Name</th><th>Fruit</th></tr>
<tr><td>Orange</td><td>Grapes</td></tr>
<tr><td>Guava</td><td>Guava</td></tr>
</table> -
21.📝 How many <input> tags are in this form?
<form>
<input type="number">
<input type="text">
<input type="submit" value="Send">
</form> -
22.🔗 Where does this link open?
<a href="about.html" target="_blank">Contact us</a> (a) in the same tab (b) in a new tab - 23.True or false: <td> holds the whole table. (a) False (b) True
- 24.🛡️ Should you share your password with your best friend? (a) No (b) Yes
- 25.Which of these does HTML do? (a) checks a quiz answer (b) sets colours and fonts (c) gives the page structure (d) changes the page live
-
26.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="kite.png" alt="A red kite" width="100"> (a) Map of India (b) kite.png (c) A red kite (d) width - 27.🔁 When does the else part run? (a) always (b) when if is false (c) never (d) when if is true
-
28.📊 How many cells does this table have in all?
<table>
<tr><td>Litchi</td><td>Guava</td><td>Mango</td></tr>
<tr><td>Papaya</td><td>Grapes</td><td>Orange</td></tr>
<tr><td>Banana</td><td>Jamun</td><td>Jamun</td></tr>
<tr><td>Orange</td><td>Orange</td><td>Banana</td></tr>
</table> - 29.🏷️ Is </p> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
30.🔒 Is the connection to this address scrambled (encrypted)?
https://www.example.com/maths/tables.html (a) No (b) Yes - 31.True or false: a code editor has an address bar. (a) False (b) True
- 32.📊 Which tag gives the table a title? (a) <th> (b) <caption> (c) <tr> (d) <table>
- 33.Which of these is not safe to do online? (a) tell a trusted adult (b) share your OTP (c) ask before downloading (d) think before you post
- 34.🌈 In #rrggbb, which colour do the first two digits give? (a) blue (b) black (c) red (d) green
- 35.⚖️ Which selector is the strongest? (a) an element selector (b) a class selector (c) an id selector
- 36.🔐 Is iloveyou a strong or a weak password? (a) strong (b) weak
- 37.🔗 Which tag makes a clickable link? (a) <p> (b) <a> (c) <img> (d) <link>
- 38.🔠 Which tag is used for the main title on a page? (a) <br> (b) <h1> (c) <h6> (d) <p>
-
39.🔁 What is the LAST number this code prints?
for (let i = 0; i < 5; i = i + 2) {
console.log(i);
} - 40.🧭 Which semantic tag holds the logo and title? (a) <header> (b) <main> (c) <footer> (d) <nav>
Answer key
- iloveyou
- https
- 17
- <header>
- alt
- an opening tag
- white on black
- 210
- Our school trip
- 242
- an element selector
- about.html
- <div id="hero">
- /art/gallery.html
- center
- <
- the screen width
- Play again
- space-between
- 2
- 3
- in a new tab
- False
- No
- gives the page structure
- A red kite
- when if is false
- 12
- a closing tag
- Yes
- False
- <caption>
- share your OTP
- red
- an id selector
- weak
- <a>
- <h1>
- 4
- <header>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids