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 list tag is an unordered list? (a) <ul> (b) <li> (c) <ol>
-
2.📋 Does this list show bullets or numbers?
<ul>
<li>Mango</li>
<li>Jamun</li>
<li>Grapes</li>
</ul> (a) bullets (b) numbers -
3.🔁 How many times does this code print “Hello”?
for (let i = 0; i <= 7; i++) {
console.log("Hello");
} - 4.True or false: console.log(5 + 2); goes in script.js. (a) False (b) True
- 5.🎯 Which element does the selector .box style? (a) <li class="box"> (b) <li class="star"> (c) <li id="box"> (d) <div class="menu">
- 6.True or false: a code editor is where we type code. (a) False (b) True
-
7.💪 How wide (px) is each gap between two boxes?
.row {
display: flex;
width: 550px;
justify-content: space-between;
}
Inside are 4 boxes, each 100px wide (no margins). -
8.🔁 How many times does this code print “Welcome”?
for (let i = 1; i < 5; i++) {
console.log("Welcome");
} - 9.📝 Which tag gives a form box a name you can click? (a) <label> (b) <title> (c) <h1> (d) <hr>
- 10.🖼️ Which attribute of <img> sets how wide it is? (a) src (b) height (c) alt (d) width
- 11.🔢 To build and share your first web page, which comes LAST? (a) write the HTML (b) plan what to show (c) publish it online (d) add CSS styles
-
12.📊 How many rows does this table have?
<table>
<tr><th>Name</th><th>Fruit</th><th>Price</th></tr>
<tr><td>Grapes</td><td>Guava</td><td>Jamun</td></tr>
<tr><td>Grapes</td><td>Jamun</td><td>Guava</td></tr>
</table> -
13.✍️ Which property is set to 8px in this rule?
#top {
font-style: italic;
padding: 8px;
color: red;
} (a) border (b) font-weight (c) padding (d) 8px - 14.🌗 Is dark grey on white easy or hard to read? (a) easy to read (b) hard to read
- 15.💪 Which flexbox property turns on flexbox? (a) flex-direction (b) justify-content (c) gap (d) display: flex
-
16.⚡ What does this code show?
let name = "Aman";
console.log("Welcome, " + name + "!"); (a) Aman (b) name (c) Welcome, Aman! (d) Welcome, name! - 17.🧩 Which language sets colours and fonts? (a) CSS (b) HTML (c) JavaScript
- 18.📦 In the box model, which part is the gap to other boxes? (a) content (b) padding (c) margin (d) border
- 19.Which of these is true of a web browser? (a) saves our .html files (b) colours code to help us (c) turns HTML into a page (d) is where we type code
- 20.True or false: HTML on its own can keep a high score. (a) False (b) True
- 21.✍️ Which sign goes between a property and its value? (a) : (b) = (c) - (d) ;
- 22.🖼️ Which attribute of <img> describes the picture? (a) src (b) width (c) height (d) alt
-
23.✍️ Which property is set to 2px solid in this rule?
.box {
border: 2px solid;
background-color: yellow;
} (a) font-style (b) border (c) width (d) 2px solid -
24.⚡ What does this code show?
let name = "Riya";
alert("Well done, " + name + "!"); (a) Well done, name! (b) Riya (c) name (d) Well done, Riya! - 25.True or false: a web browser saves our .html files. (a) True (b) False
- 26.🖌️ Which CSS property colours behind the text? (a) background-color (b) text-align (c) color (d) font-size
- 27.Which of these is an empty tag? (a) <input> (b) <p> (c) <ul> (d) <b>
- 28.📊 Where do <td> cells go? (a) inside a <li> (b) inside the <head> (c) inside a <tr> (d) inside a <p>
- 29.🧭 Is <header> semantic or not semantic? (a) semantic (b) not semantic
- 30.📊 Which tag gives the table a title? (a) <caption> (b) <td> (c) <tr> (d) <th>
- 31.Which colour pair is easy to read? (a) light grey on white (b) pink on red (c) black on white (d) yellow on white
-
32.🌍 What is the protocol in this URL?
http://school.example.in/news/today.html (a) http (b) https (c) /news/today.html (d) school.example.in - 33.🏷️ Every HTML tag starts with which sign? (a) { (b) [ (c) < (d) (
-
34.💬 How many paragraphs show on the page?
<!-- <p>Good morning!</p> -->
<p>My pets</p>
<!-- <p>Cricket is fun.</p> --> - 35.True or false: in <img>, alt shows if the image fails. (a) False (b) True
- 36.🌐 Which one colours code to help us? (a) a code editor (b) a web browser (c) a web server
-
37.✍️ What is the selector in this CSS rule?
li {
width: 300px;
color: red;
background-color: yellow;
} (a) body (b) red (c) li (d) width - 38.Which of these is true of <article>? (a) holds a news story (b) sits at the bottom (c) sits at the very top (d) holds a side box of tips
- 39.🧩 Which language lays out the page? (a) JavaScript (b) HTML (c) CSS
- 40.📝 Which input type is for one line of words? (a) text (b) radio (c) date (d) submit
Answer key
- <ul>
- bullets
- 8
- True
- <li class="box">
- True
- 50
- 4
- <label>
- width
- publish it online
- 3
- padding
- easy to read
- display: flex
- Welcome, Aman!
- CSS
- margin
- turns HTML into a page
- False
- :
- alt
- border
- Well done, Riya!
- False
- background-color
- <input>
- inside a <tr>
- semantic
- <caption>
- black on white
- http
- <
- 1
- True
- a code editor
- li
- holds a news story
- CSS
- text
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids