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 pixels wide is the picture drawn?
<img src="map.png" alt="Map of India" width="350"> - 2.🌈 Which colour of light is strongest in rgb(140, 168, 9)? (a) green (b) red (c) blue
-
3.📊 How many rows does this table have?
<table>
<tr><th>Name</th><th>Fruit</th><th>Price</th></tr>
<tr><td>Jamun</td><td>Guava</td><td>Papaya</td></tr>
</table> -
4.⚖️ What colour is the text of this element?
<h2 class="menu" id="logo">Hi</h2>
CSS:
#logo { color: yellow; }
#logo { color: green; } (a) yellow (b) blue (c) green (d) white -
5.📱 The screen is 320px wide. What font-size (px) does the paragraph get?
p {
font-size: 12px;
}
@media (max-width: 1024px) {
p {
font-size: 8px;
}
} -
6.📊 How many rows does this table have?
<table>
<tr><td>Grapes</td><td>Jamun</td></tr>
<tr><td>Mango</td><td>Guava</td></tr>
</table> - 7.🌗 Is white on black easy or hard to read? (a) easy to read (b) hard to read
- 8.🧩 Which language makes a link? (a) JavaScript (b) HTML (c) CSS
- 9.🏷️ Is <h1> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
- 10.🧩 Which language gives the page structure? (a) CSS (b) JavaScript (c) HTML
- 11.True or false: <input> has a closing tag. (a) True (b) False
- 12.✍️ How does a CSS comment start? (a) <!-- (b) # (c) /* (d) //
-
13.📝 How many paragraphs does this code make?
<p>I love mangoes.</p>
<h2>Cricket is fun.</h2>
<h2>Hello, world!</h2> -
14.📝 On how many lines does the browser show this paragraph?
<p>Rivers flow<br>Birds sing<br>Stars shine</p> - 15.True or false: <h1> goes in the body. (a) False (b) True
- 16.🛡️ Online: is it safe to share your OTP? (a) not safe (b) safe
-
17.📦 How wide (px) is this box from the outer edge of its left border to the outer edge of its right border?
.box {
width: 150px;
padding: 30px;
border: 1px solid black;
margin: 5px;
} -
18.💪 How much empty space (px) is before the first box?
.row {
display: flex;
width: 240px;
justify-content: center;
}
Inside are 2 boxes, each 100px wide (no margins). - 19.Which of these is a strong password? (a) riya2014 (b) abcd1234 (c) Chai$Cup_19x (d) password
-
20.💪 How much empty space (px) is before the first box?
.row {
display: flex;
width: 180px;
justify-content: flex-end;
}
Inside are 3 boxes, each 40px wide (no margins). - 21.Which of these is an empty tag? (a) <ul> (b) <p> (c) <br> (d) <b>
- 22.True or false: “write clear link text” makes the page harder to use. (a) False (b) True
- 23.Which of these is true of a web browser? (a) hosts websites online (b) answers page requests (c) colours code to help us (d) opens web pages for us
-
24.🌍 What is the path in this URL?
http://kids.example.org/news/today.html (a) kids.example.org (b) http (c) /news/today.html (d) /games/chess.html -
25.🖌️ What colour are the letters?
p {
color: yellow;
background-color: green;
font-size: 32px;
text-align: right;
} (a) black (b) green (c) yellow - 26.📝 Which input type picks a day? (a) submit (b) password (c) number (d) date
-
27.🔁 What number does this code print?
let total = 0;
for (let i = 1; i <= 7; i++) {
total = total + 3;
}
console.log(total); - 28.🏷️ Is <title> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
-
29.📝 At most, how many of these can be chosen at the same time?
<form>
<input type="radio" name="colour"> Green
<input type="radio" name="colour"> Red
<input type="radio" name="colour"> Orange
</form> -
30.🔠 How many headings are in this code?
<h1>The red kite</h1>
<h2>The red kite</h2>
<p>Our school trip</p>
<p>Fun facts</p> - 31.🖼️ Why do we add alt text to an image? (a) to make it bigger (b) to colour it (c) to describe the image (d) to load it faster
- 32.What does background-color do? (a) sets the letter colour (b) makes letters bigger (c) colours behind the text (d) picks the font style
- 33.🚀 Which file should this code go in: alert("Hi"); (a) script.js (b) index.html (c) style.css
- 34.Which of these is not safe to do online? (a) keep passwords secret (b) share your OTP (c) tell a trusted adult (d) think before you post
- 35.🔢 To build and share your first web page, which comes first: “write the HTML” or “publish it online”? (a) publish it online (b) write the HTML
- 36.What is <input type="text"> for? (a) takes only numbers (b) is for one line of words (c) is for an email address (d) lets you pick only one
- 37.⚖️ Two rules with the same selector set a colour. Which one wins? (a) the later one (b) the shorter one (c) neither (d) the first one
- 38.🔗 What does target="_blank" do to a link? (a) makes it blank (b) makes it bold (c) opens it in a new tab (d) hides the link
- 39.True or false: HTML gives the page structure. (a) False (b) True
-
40.📝 How many paragraphs does this code make?
<p>My pets</p>
<p>Fun facts</p>
<h2>Hello, world!</h2>
<p>Cricket is fun.</p>
<h2>I love mangoes.</h2>
<p>Rain today</p>
Answer key
- 350
- green
- 2
- green
- 8
- 2
- easy to read
- HTML
- an opening tag
- HTML
- False
- /*
- 1
- 3
- True
- not safe
- 212
- 20
- Chai$Cup_19x
- 60
- <br>
- False
- opens web pages for us
- /news/today.html
- yellow
- date
- 21
- an opening tag
- 1
- 2
- to describe the image
- colours behind the text
- script.js
- share your OTP
- write the HTML
- is for one line of words
- the later one
- opens it in a new tab
- True
- 4
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids