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 true of a code editor? (a) has an address bar (b) hosts websites online (c) saves our .html files (d) shows pages from the web
- 2.True or false: in <img>, height is read by screen readers. (a) True (b) False
- 3.🎯 What kind of selector is p? (a) an id selector (b) a class selector (c) an element selector
- 4.📦 In the box model, which part is the line round the box? (a) padding (b) content (c) margin (d) border
-
5.✍️ Which property is set to italic in this rule?
.note {
color: red;
padding: 8px;
font-weight: bold;
font-style: italic;
} (a) italic (b) font-size (c) color (d) font-style - 6.Which of these is an empty tag? (a) <img> (b) <ul> (c) <h1> (d) <title>
- 7.🎯 Which element does the selector .note style? (a) <h2 class="red"> (b) <h1 id="note"> (c) <h1 class="note"> (d) <h1 class="big">
-
8.🖌️ What colour are the letters?
h2 {
color: orange;
font-size: 16px;
background-color: white;
text-align: right;
} (a) white (b) orange (c) purple -
9.🖼️ How many pixels wide is the picture drawn?
<img src="cake.jpg" alt="Birthday cake" width="100"> - 10.True or false: <li> has a closing tag. (a) True (b) False
- 11.True or false: <caption> gives the table a title. (a) False (b) True
-
12.📝 At most, how many of these can be chosen at the same time?
<form>
<input type="radio" name="colour"> Pink
<input type="radio" name="colour"> Blue
<input type="radio" name="colour"> Green
<input type="radio" name="colour"> Orange
<input type="radio" name="colour"> Red
</form> - 13.True or false: <input type="password"> sends the form. (a) False (b) True
-
14.📱 The screen is 1366px wide. Does the rule inside @media apply?
p {
font-size: 16px;
}
@media (max-width: 768px) {
p {
font-size: 12px;
}
} (a) No (b) Yes - 15.📋 Which list tag shows 1, 2, 3 numbers? (a) <li> (b) <ol> (c) <ul>
-
16.🔁 How many times does this code print “Hi”?
for (let i = 3; i < 8; i++) {
console.log("Hi");
} - 17.🖌️ Which CSS property colours behind the text? (a) background-color (b) color (c) text-align (d) font-family
- 18.🚀 Which file is best for the colours and fonts? (a) photo.jpg (b) script.js (c) style.css (d) index.html
- 19.🔠 Which heading shows the BIGGEST text: <h2>, <h6>, <h4> or <h3>? (a) <h6> (b) <h2> (c) <h3> (d) <h4>
- 20.True or false: HTML on its own cannot make tables. (a) False (b) True
- 21.📄 Where does <table> go: in the head or in the body? (a) in the body (b) in the head
-
22.✍️ What is the selector in this CSS rule?
h1 {
font-size: 20px;
background-color: yellow;
} (a) font-size (b) yellow (c) p (d) h1 - 23.True or false: alert("Hi"); goes in script.js. (a) True (b) False
- 24.Which of these is an empty tag? (a) <ul> (b) <li> (c) <hr> (d) <b>
- 25.Which of these is true of a web browser? (a) answers page requests (b) sends pages over the net (c) saves our .html files (d) shows pages from the web
-
26.⚡ What does this code show?
let name = "Arjun";
alert("Hello, " + name + "!"); (a) Hello, Arjun! (b) Arjun (c) Hello, name! (d) name - 27.True or false: <link rel="stylesheet"> goes in the body. (a) False (b) True
- 28.True or false: <td> holds the whole table. (a) False (b) True
- 29.True or false: in <img>, src names the picture file. (a) False (b) True
-
30.⚖️ What colour is the text of this element?
<h1 class="box" id="logo">Hi</h1>
CSS:
.box { color: yellow; }
.box { color: purple; } (a) purple (b) yellow (c) white (d) black - 31.✍️ Which sign goes between a property and its value? (a) ; (b) = (c) - (d) :
- 32.🔗 Which code links to about.html? (a) <a alt="about.html"> (b) <a href="about.html"> (c) <a src="about.html"> (d) <link about.html>
- 33.🛡️ Online: is it safe to type a password on http? (a) not safe (b) safe
-
34.📝 At most, how many of these can be chosen at the same time?
<form>
<input type="radio" name="sport"> Hockey
<input type="radio" name="sport"> Kabaddi
<input type="radio" name="sport"> Cricket
<input type="radio" name="sport"> Football
<input type="radio" name="sport"> Chess
</form> - 35.True or false: a web server saves our .html files. (a) True (b) False
- 36.🔠 Which heading shows the SMALLEST text: <h6>, <h1>, <h4> or <h3>? (a) <h6> (b) <h4> (c) <h1> (d) <h3>
- 37.📦 In the box model, which part is a solid or dotted edge? (a) padding (b) margin (c) border (d) content
-
38.📱 The screen is 320px wide. What font-size (px) does the paragraph get?
p {
font-size: 24px;
}
@media (min-width: 1024px) {
p {
font-size: 26px;
}
} - 39.🌍 Which one scrambles data on its way? (a) HTTPS (b) the URL (c) the browser (d) the server
- 40.Which of these is a weak password? (a) 111111 (b) Blue@Tiger_74 (c) Rain#Drop_42! (d) Mango#Kite29!
Answer key
- saves our .html files
- False
- an element selector
- border
- font-style
- <img>
- <h1 class="note">
- orange
- 100
- True
- True
- 1
- False
- No
- <ol>
- 5
- background-color
- style.css
- <h2>
- False
- in the body
- h1
- True
- <hr>
- shows pages from the web
- Hello, Arjun!
- False
- False
- True
- purple
- :
- <a href="about.html">
- not safe
- 1
- False
- <h6>
- border
- 24
- HTTPS
- 111111
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids