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.📝 How many paragraphs does this code make?
<p>The red kite</p>
<h2>Hello, world!</h2>
<p>Fun facts</p>
<p>Our school trip</p>
<p>I love mangoes.</p>
<h2>Cricket is fun.</h2> - 2.True or false: HTML on its own can run a game loop. (a) True (b) False
- 3.True or false: .big is a class selector. (a) False (b) True
- 4.🧭 Why use <nav> instead of <div> for a menu? (a) it adds pictures (b) it tells its meaning (c) it makes text red (d) it loads faster
-
5.💪 How wide (px) is each gap between two boxes?
.row {
display: flex;
width: 140px;
justify-content: space-between;
}
Inside are 3 boxes, each 40px wide (no margins). - 6.📦 In the box model, which part is space outside the border? (a) margin (b) padding (c) content (d) border
- 7.📋 Which list shows the steps of a recipe best? (a) <ol> (b) <hr> (c) <br> (d) <ul>
-
8.📱 The screen is 320px wide. Does the rule inside @media apply?
p {
font-size: 24px;
}
@media (max-width: 768px) {
p {
font-size: 18px;
}
} (a) No (b) Yes - 9.🔐 Is Rain#Drop_42! a strong or a weak password? (a) weak (b) strong
- 10.⚖️ Which selector is the weakest? (a) an element selector (b) an id selector (c) a class selector
- 11.True or false: in <img>, src names the picture file. (a) False (b) True
-
12.🔗 Which words do you click on?
<a href="art.html">Take the quiz</a> (a) Take the quiz (b) art.html (c) Play games (d) href - 13.📝 Which tag gives a form box a name you can click? (a) <h1> (b) <label> (c) <hr> (d) <title>
-
14.🔁 How many numbers does this code print?
for (let i = 0; i < 17; i = i + 4) {
console.log(i);
} - 15.🛡️ Before typing a password on a site, check the address starts with ___. (a) www (b) https (c) ftp (d) http
-
16.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="fort.jpg" alt="An old fort" width="250"> (a) width (b) fort.jpg (c) A tiger asleep (d) An old fort - 17.🌗 Is white on dark blue easy or hard to read? (a) hard to read (b) easy to read
- 18.📝 Which input type picks a day? (a) password (b) date (c) number (d) radio
- 19.📄 Where does the text of <title> appear? (a) in a big heading (b) on the browser tab (c) nowhere (d) at the bottom
-
20.💬 How many paragraphs show on the page?
<!-- <p>My pets</p> -->
<p>Fun facts</p>
<p>Rain today</p> - 21.🚀 What is the home page file of a website usually called? (a) start.js (b) index.html (c) main.png (d) home.css
-
22.📦 How much space across (px) does this box take in all, margin included?
.box {
width: 260px;
padding: 25px;
border: 5px solid black;
margin: 5px;
} -
23.🔁 What is the LAST number this code prints?
for (let i = 0; i < 7; i = i + 3) {
console.log(i);
} - 24.True or false: “use headings in order” makes the page harder to use. (a) True (b) False
-
25.🌍 What is the path in this URL?
http://learn.example.com/about.html (a) http (b) learn.example.com (c) /maths/tables.html (d) /about.html - 26.🔍 Which is the odd one out? (a) rounds box corners (b) lays out the page (c) makes headings and lists (d) adds space around boxes
- 27.True or false: to download from pop-ups is not safe. (a) False (b) True
- 28.🚀 Which file should this code go in: score = score + 1; (a) style.css (b) script.js (c) index.html
- 29.📋 Which list tag is an ordered list? (a) <li> (b) <ol> (c) <ul>
- 30.Which of these is a weak password? (a) abcd1234 (b) Mango#Kite29! (c) Blue@Tiger_74 (d) Rain#Drop_42!
- 31.Which of these is not safe to do online? (a) use a strong password (b) tell a trusted adult (c) use a nickname in games (d) share your password
- 32.Which of these is margin? (a) a solid or dotted edge (b) the gap round content (c) space outside the border (d) space inside the border
- 33.True or false: <input type="text"> is for one line of words. (a) True (b) False
- 34.📱 What does a media query check? (a) the battery level (b) the time of day (c) the screen width (d) the page title
- 35.🛡️ Should you share your password with your best friend? (a) No (b) Yes
- 36.📋 Which list tag lists things in any order? (a) <ul> (b) <ol> (c) <li>
- 37.📝 Which tag holds a whole form? (a) <ol> (b) <table> (c) <input> (d) <form>
- 38.True or false: CSS puts a picture on a page. (a) True (b) False
- 39.💪 Which flexbox property picks row or column? (a) justify-content (b) align-items (c) flex-direction (d) gap
-
40.✍️ What is the selector in this CSS rule?
h1 {
font-style: italic;
width: 300px;
} (a) p (b) font-style (c) h1 (d) 300px
Answer key
- 4
- False
- True
- it tells its meaning
- 10
- margin
- <ol>
- Yes
- strong
- an element selector
- True
- Take the quiz
- <label>
- 5
- https
- An old fort
- easy to read
- date
- on the browser tab
- 2
- index.html
- 330
- 6
- False
- /about.html
- makes headings and lists
- True
- script.js
- <ol>
- abcd1234
- share your password
- space outside the border
- True
- the screen width
- No
- <ul>
- <form>
- False
- flex-direction
- h1
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids