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 safe to do online? (a) log out on shared PCs (b) share your password (c) type a password on http (d) post your home address
-
2.🔠 How many headings are in this code?
<h1>Good morning!</h1>
<h3>Fun facts</h3>
<p>My best friend</p>
<p>Good morning!</p> -
3.💪 How much empty space (px) is before the first box?
.row {
display: flex;
width: 130px;
justify-content: flex-end;
}
Inside are 2 boxes, each 60px wide (no margins). -
4.📱 The screen is 700px wide. Does the rule inside @media apply?
p {
font-size: 12px;
}
@media (max-width: 1024px) {
p {
font-size: 8px;
}
} (a) No (b) Yes -
5.🔁 What number does this code print?
let total = 0;
for (let i = 1; i <= 9; i++) {
total = total + i;
}
console.log(total); - 6.What does font-weight do? (a) makes letters bigger (b) centres a heading (c) makes the text bold (d) picks the font style
-
7.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="tiger.jpg" alt="A tiger asleep" width="100"> (a) A red kite (b) tiger.jpg (c) width (d) A tiger asleep - 8.True or false: CSS sets colours and fonts. (a) False (b) True
- 9.🌐 Which one has an address bar? (a) a web browser (b) a code editor (c) a web server
- 10.🔍 Which is the odd one out? (a) changes the page live (b) lays out the page (c) reacts to a button click (d) checks a quiz answer
- 11.⚖️ Two rules with the same selector set a colour. Which one wins? (a) the shorter one (b) neither (c) the first one (d) the later one
-
12.📋 What number does the browser show next to “Grapes”?
<ol start="4">
<li>Papaya</li>
<li>Grapes</li>
<li>Mango</li>
<li>Jamun</li>
</ol> - 13.Which of these is not safe to do online? (a) log out on shared PCs (b) keep passwords secret (c) post your home address (d) use a nickname in games
- 14.🌈 Hex digits go 0 to 9, then A to which letter? (a) J (b) F (c) G (d) Z
- 15.Which of these is an opening tag? (a) </li> (b) <title> (c) </h1> (d) </body>
-
16.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="dog.jpg" alt="A happy dog" width="250"> (a) The full moon (b) dog.jpg (c) A happy dog (d) width - 17.Which of these is padding? (a) a solid or dotted edge (b) space inside the border (c) space outside the border (d) the gap to other boxes
- 18.🧩 Which language makes headings and lists? (a) HTML (b) JavaScript (c) CSS
- 19.📦 In the box model, which part is space inside the border? (a) margin (b) content (c) border (d) padding
- 20.True or false: <ol> shows bullet points. (a) True (b) False
-
21.📝 How many paragraphs does this code make?
<p>My pets</p>
<h2>Good morning!</h2>
<p>My best friend</p>
<h2>Cricket is fun.</h2>
<p>Rain today</p>
<h2>I love mangoes.</h2> -
22.📱 The screen is 414px wide. What font-size (px) does the paragraph get?
p {
font-size: 12px;
}
@media (max-width: 768px) {
p {
font-size: 10px;
}
} -
23.✍️ Which property is set to center in this rule?
h2 {
text-align: center;
margin: 10px;
font-weight: bold;
color: red;
} (a) margin (b) center (c) background-color (d) text-align -
24.🔁 What is the LAST number this code prints?
for (let i = 0; i < 7; i = i + 2) {
console.log(i);
} - 25.Which of these is a strong password? (a) Kite_Fl1es@Dawn (b) qwerty (c) riya2014 (d) password
- 26.True or false: in <img>, alt sets how tall it is. (a) True (b) False
- 27.True or false: HTML on its own can add pictures to a page. (a) False (b) True
-
28.⚡ What number does this code print?
let marks = 27;
marks = marks + 4;
marks = marks - 29;
console.log(marks); - 29.🎨 One CSS file can style how many pages? (a) only one word (b) no pages (c) many pages (d) only one image
- 30.🎯 What kind of selector is body? (a) a class selector (b) an id selector (c) an element selector
-
31.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="map.png" alt="Map of India" width="250"> (a) map.png (b) Birthday cake (c) Map of India (d) width -
32.📝 On how many lines does the browser show this paragraph?
<p>Stars shine<br>Kites fly high<br>Rivers flow</p> - 33.Which of these is padding? (a) the text or picture (b) a solid or dotted edge (c) space outside the border (d) the gap round content
- 34.🖌️ Which CSS property centres a heading? (a) text-align (b) color (c) font-family (d) background-color
-
35.🔗 Which words do you click on?
<a href="art.html">Art corner</a> (a) art.html (b) Art corner (c) School news (d) href -
36.🔒 Is the connection to this address scrambled (encrypted)?
https://learn.example.com/index.html (a) No (b) Yes - 37.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as a dot (b) as 5 spaces (c) as one space (d) as a new line
- 38.🔠 Which heading shows the BIGGEST text: <h1>, <h3>, <h4> or <h5>? (a) <h1> (b) <h3> (c) <h5> (d) <h4>
- 39.🧭 Who is helped most by semantic tags? (a) screen-reader users (b) only the server (c) only the printer (d) nobody
- 40.🛡️ Should you share your password with your best friend? (a) No (b) Yes
Answer key
- log out on shared PCs
- 2
- 10
- Yes
- 45
- makes the text bold
- A tiger asleep
- True
- a web browser
- lays out the page
- the later one
- 5
- post your home address
- F
- <title>
- A happy dog
- space inside the border
- HTML
- padding
- False
- 3
- 10
- text-align
- 6
- Kite_Fl1es@Dawn
- False
- True
- 2
- many pages
- an element selector
- Map of India
- 3
- the gap round content
- text-align
- Art corner
- Yes
- as one space
- <h1>
- screen-reader users
- No
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids