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 one turns HTML into a page? (a) a code editor (b) a web browser (c) a web server
- 2.✍️ How does a CSS comment start? (a) /* (b) // (c) # (d) <!--
- 3.⚖️ Two rules with the same selector set a colour. Which one wins? (a) the later one (b) the first one (c) the shorter one (d) neither
- 4.💪 Which justify-content value equal gaps, none at ends? (a) center (b) flex-end (c) space-between (d) flex-start
- 5.📱 Which tag helps phones show a page at the right size? (a) the br tag (b) the title tag (c) the hr tag (d) the viewport meta tag
-
6.📱 The screen is 700px wide. What font-size (px) does the paragraph get?
p {
font-size: 24px;
}
@media (min-width: 480px) {
p {
font-size: 28px;
}
} - 7.🏷️ Which is the closing tag for <u>? (a) <\u> (b) </u> (c) <u/> (d) <u>
-
8.⚖️ What colour is the text of this element?
<p class="menu" id="top">Hi</p>
CSS:
p { color: red; }
#top { color: orange; } (a) red (b) orange (c) yellow (d) green - 9.Which of these is a closing tag? (a) </title> (b) <body> (c) <p> (d) <li>
- 10.🚀 Where in index.html does the link to style.css go? (a) in the footer (b) after </html> (c) in the head (d) inside a <p>
- 11.True or false: <meta charset="utf-8"> goes in the body. (a) True (b) False
- 12.🌈 In #rrggbb, which colour do the last two digits give? (a) blue (b) green (c) red (d) white
-
13.🔗 Which words do you click on?
<a href="maths.html">Maths fun</a> (a) maths.html (b) Art corner (c) Maths fun (d) href - 14.True or false: to think before you post is safe. (a) False (b) True
- 15.True or false: <p> is an empty tag. (a) False (b) True
- 16.🎯 How many elements on a page should have the same id? (a) 5 (b) 2 (c) any number (d) 1
- 17.Which of these is not safe to do online? (a) type a password on http (b) tell a trusted adult (c) use a strong password (d) think before you post
- 18.🧩 Which language adds space around boxes? (a) JavaScript (b) CSS (c) HTML
-
19.✍️ How many declarations (property: value pairs) are in this rule?
li {
color: red;
padding: 8px;
} -
20.✍️ How many declarations (property: value pairs) are in this rule?
.note {
font-size: 20px;
} - 21.True or false: the border is space inside the border. (a) True (b) False
-
22.⚡ What number does this code print?
let apples = 8;
apples = apples + 13;
apples = apples - 21;
console.log(apples); - 23.✍️ Which sign ends each CSS declaration? (a) ; (b) . (c) : (d) ,
- 24.🏷️ Is <body> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
- 25.⚡ Which JavaScript word makes a new variable? (a) console.log() (b) if (c) let (d) for
- 26.Which of these does JavaScript do? (a) changes the page live (b) changes the text size (c) puts a picture on a page (d) makes headings and lists
- 27.Which of these is true of <footer>? (a) holds copyright notes (b) holds a news story (c) sits at the very top (d) holds extra side notes
- 28.🔠 Which heading shows the BIGGEST text: <h6>, <h1>, <h4> or <h3>? (a) <h4> (b) <h3> (c) <h6> (d) <h1>
- 29.📛 In <a href="x.html">, what is href? (a) an element name (b) a closing tag (c) a comment (d) an attribute
- 30.🎯 What kind of selector is h1? (a) a class selector (b) an element selector (c) an id selector
- 31.🖼️ Which attribute of <img> sets how wide it is? (a) alt (b) width (c) src (d) height
-
32.💪 How much empty space (px) is left after the last box?
.row {
display: flex;
width: 140px;
justify-content: flex-start;
}
Inside are 3 boxes, each 40px wide (no margins). - 33.Which of these is true of a web server? (a) colours code to help us (b) shows line numbers (c) stores a website’s files (d) shows pages from the web
- 34.📊 Which tag makes one data cell? (a) <table> (b) <caption> (c) <td> (d) <tr>
- 35.🌈 In #rrggbb, which colour do the first two digits give? (a) black (b) blue (c) red (d) green
- 36.🔠 Which heading shows the BIGGEST text: <h3>, <h4>, <h2> or <h1>? (a) <h4> (b) <h1> (c) <h2> (d) <h3>
-
37.🔁 What number does this code print?
let total = 0;
for (let i = 1; i <= 8; i++) {
total = total + 8;
}
console.log(total); - 38.True or false: <li> shows bullet points. (a) True (b) False
- 39.🔗 Which attribute holds the address of a link? (a) alt (b) src (c) href (d) id
-
40.🔗 Which address opens when you click this link?
<a href="art.html">About us</a> (a) art.html (b) news.html (c) quiz.html (d) About us
Answer key
- a web browser
- /*
- the later one
- space-between
- the viewport meta tag
- 28
- </u>
- orange
- </title>
- in the head
- False
- blue
- Maths fun
- True
- False
- 1
- type a password on http
- CSS
- 2
- 1
- False
- 0
- ;
- an opening tag
- let
- changes the page live
- holds copyright notes
- <h1>
- an attribute
- an element selector
- width
- 20
- stores a website’s files
- <td>
- red
- <h1>
- 64
- False
- href
- art.html
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids