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.📱 The screen is 820px wide. Does the rule inside @media apply?
p {
font-size: 12px;
}
@media (min-width: 480px) {
p {
font-size: 18px;
}
} (a) No (b) Yes - 2.🚀 Which file should this code go in: p { color: red; } (a) script.js (b) index.html (c) style.css
- 3.🔍 Which is the odd one out? (a) saves our .html files (b) shows pages from the web (c) shows line numbers (d) colours code to help us
- 4.📋 Which list tag lists things in any order? (a) <li> (b) <ol> (c) <ul>
- 5.Which of these is safe to do online? (a) download from pop-ups (b) share your password (c) log out on shared PCs (d) click prize links
- 6.🖼️ Which attribute of <img> tells which image to load? (a) width (b) src (c) alt (d) height
- 7.📝 Which input type is for one line of words? (a) email (b) date (c) text (d) number
- 8.True or false: h1 { font-size: 32px; } goes in style.css. (a) False (b) True
- 9.♿ Does this help everyone, or make the page harder to use: link text “click here”? (a) helps everyone (b) makes it harder
- 10.True or false: margin is space outside the border. (a) True (b) False
- 11.🏷️ Is </li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
12.📋 Does this list show bullets or numbers?
<ul>
<li>Papaya</li>
<li>Mango</li>
<li>Jamun</li>
</ul> (a) numbers (b) bullets - 13.✍️ Which sign ends each CSS declaration? (a) , (b) . (c) ; (d) :
-
14.♿ Is this heading order correct (no level skipped)?
<h1> → <h2> → <h3> → <h4> (a) No (b) Yes - 15.True or false: <meta> has a closing tag. (a) False (b) True
- 16.📝 What does <br> do? (a) makes text bold (b) makes a list (c) adds a picture (d) starts a new line
-
17.⚡ What number does this code print?
let coins = 15;
coins = coins + 2;
coins = coins - 13;
console.log(coins); -
18.📱 The screen is 375px wide. Does the rule inside @media apply?
p {
font-size: 16px;
}
@media (max-width: 768px) {
p {
font-size: 12px;
}
} (a) No (b) Yes - 19.📦 In the box model, which part is space inside the border? (a) margin (b) content (c) padding (d) border
- 20.📄 Where does <p> go: in the head or in the body? (a) in the head (b) in the body
-
21.🔠 How many headings are in this code?
<h1>Our school trip</h1>
<p>Hello, world!</p>
<p>Cricket is fun.</p> - 22.True or false: JavaScript changes the text size. (a) False (b) True
- 23.🧩 Which language adds space around boxes? (a) CSS (b) JavaScript (c) HTML
-
24.📝 How many <input> tags are in this form?
<form>
<input type="date">
<input type="password">
<input type="submit" value="Send">
</form> - 25.✍️ How does a CSS comment start? (a) /* (b) // (c) <!-- (d) #
- 26.🔠 Which heading shows the SMALLEST text: <h1>, <h2>, <h5> or <h4>? (a) <h2> (b) <h4> (c) <h5> (d) <h1>
-
27.📱 The screen is 375px wide. What font-size (px) does the paragraph get?
p {
font-size: 24px;
}
@media (max-width: 1024px) {
p {
font-size: 22px;
}
} - 28.📦 In the box model, which part is the gap to other boxes? (a) border (b) margin (c) content (d) padding
- 29.🛡️ Online: is it safe to check for https first? (a) not safe (b) safe
- 30.📝 Which input type sends the form? (a) submit (b) password (c) radio (d) text
- 31.Which of these goes in the head? (a) <title> (b) <ul> (c) <a> (d) <table>
-
32.🖌️ Where does the text sit on its line?
h1 {
font-size: 32px;
color: black;
text-align: left;
background-color: blue;
} (a) on the left (b) in the middle (c) on the right - 33.📝 What does <hr> draw? (a) a picture (b) a table (c) a link (d) a line across the page
- 34.Which of these is true of a web server? (a) sends pages over the net (b) saves our .html files (c) shows line numbers (d) has an address bar
- 35.True or false: <article> holds the main content. (a) False (b) True
- 36.🌈 In #rrggbb, which colour do the first two digits give? (a) red (b) blue (c) green (d) black
-
37.🔁 How many numbers does this code print?
for (let i = 0; i < 15; i = i + 2) {
console.log(i);
} - 38.🧭 How many <main> parts should a page have? (a) ten (b) none (c) three (d) one
-
39.📱 The screen is 540px wide. Does the rule inside @media apply?
p {
font-size: 24px;
}
@media (min-width: 600px) {
p {
font-size: 26px;
}
} (a) No (b) Yes - 40.📋 Which list tag lists steps in order? (a) <ul> (b) <ol> (c) <li>
Answer key
- Yes
- style.css
- shows pages from the web
- <ul>
- log out on shared PCs
- src
- text
- True
- makes it harder
- True
- a closing tag
- bullets
- ;
- Yes
- False
- starts a new line
- 4
- Yes
- padding
- in the body
- 1
- False
- CSS
- 3
- /*
- <h5>
- 22
- margin
- safe
- submit
- <title>
- on the left
- a line across the page
- sends pages over the net
- False
- red
- 8
- one
- No
- <ol>
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids