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 JavaScript word repeats code? (a) alert() (b) if (c) let (d) for
-
2.⚡ What number does this code print?
let a = 6;
let b = 7;
console.log(a * b); - 3.🔗 Which code links to about.html? (a) <link about.html> (b) <a alt="about.html"> (c) <a src="about.html"> (d) <a href="about.html">
-
4.🔗 Which words do you click on?
<a href="contact.html">About us</a> (a) href (b) Contact us (c) About us (d) contact.html - 5.🚀 Which file is best for code that reacts to clicks? (a) notes.txt (b) script.js (c) style.css (d) index.html
-
6.📊 How many heading cells (<th>) does this table have?
<table>
<tr><th>Name</th><th>Fruit</th></tr>
<tr><td>Litchi</td><td>Jamun</td></tr>
<tr><td>Grapes</td><td>Papaya</td></tr>
</table> - 7.⚡ Which JavaScript word runs code when true? (a) console.log() (b) let (c) alert() (d) if
- 8.⚖️ Which selector is the weakest? (a) an id selector (b) an element selector (c) a class selector
-
9.⚖️ What colour is the text of this element?
<h1 class="big" id="intro">Hi</h1>
CSS:
.big { color: white; }
.big { color: blue; } (a) blue (b) red (c) green (d) white - 10.🌈 Which colour is #0000ff? (a) yellow (b) magenta (c) blue (d) red
-
11.♿ Is this heading order correct (no level skipped)?
<h1> → <h3> → <h4> → <h5> (a) Yes (b) No - 12.True or false: in <img>, height sets how tall it is. (a) False (b) True
- 13.True or false: <input type="radio"> lets you pick only one. (a) False (b) True
-
14.⚖️ What colour is the text of this element?
<h1 class="star" id="intro">Hi</h1>
CSS:
.star { color: red; }
h1 { color: green; }
#intro { color: black; } (a) black (b) purple (c) green (d) red - 15.📄 Which part holds everything you see on the page? (a) the title (b) the head (c) the body (d) the doctype
-
16.📋 How many items does this list show?
<ul>
<li>Orange</li>
<li>Papaya</li>
<li>Litchi</li>
<li>Jamun</li>
</ul> - 17.📊 Which tag holds the whole table? (a) <tr> (b) <th> (c) <table> (d) <caption>
-
18.📦 How much space top to bottom (px) does this box take in all, margin included?
.box {
height: 40px;
padding: 30px;
border: 2px solid black;
margin: 15px;
} -
19.📊 How many rows does this table have?
<table>
<tr><td>Guava</td><td>Grapes</td></tr>
<tr><td>Papaya</td><td>Litchi</td></tr>
</table> - 20.📝 Which input type is for one line of words? (a) text (b) date (c) submit (d) email
- 21.⚡ Which word makes a new variable? (a) put (b) let (c) give (d) make
-
22.⚡ What does this code show?
let name = "Arjun";
console.log("Welcome, " + name + "!"); (a) Welcome, name! (b) Arjun (c) name (d) Welcome, Arjun! - 23.🔠 Which heading shows the SMALLEST text: <h2>, <h3>, <h1> or <h4>? (a) <h4> (b) <h1> (c) <h3> (d) <h2>
- 24.Which of these is not safe to do online? (a) think before you post (b) keep passwords secret (c) tell a trusted adult (d) download from pop-ups
- 25.True or false: <tr> makes one table row. (a) False (b) True
- 26.🖌️ Which CSS property makes letters bigger? (a) background-color (b) color (c) font-weight (d) font-size
-
27.🔍 Which line is missing its closing tag?
line 1: <strong>Cricket is fun.</strong>
line 2: <i>Hello, world!</i>
line 3: <em>Fun facts (a) line 1 (b) line 2 (c) line 3 - 28.🔠 Which heading shows the SMALLEST text: <h1>, <h2>, <h6> or <h4>? (a) <h1> (b) <h6> (c) <h2> (d) <h4>
-
29.📱 The screen is 320px wide. What font-size (px) does the paragraph get?
p {
font-size: 24px;
}
@media (min-width: 480px) {
p {
font-size: 28px;
}
} - 30.What is <input type="submit"> for? (a) hides what you type (b) lets you tick many (c) sends the form (d) takes only numbers
-
31.🔗 Which words do you click on?
<a href="contact.html">School news</a> (a) href (b) Take the quiz (c) contact.html (d) School news - 32.🧭 Is <footer> semantic or not semantic? (a) semantic (b) not semantic
- 33.🧭 Why use <nav> instead of <div> for a menu? (a) it loads faster (b) it tells its meaning (c) it adds pictures (d) it makes text red
-
34.📊 How many cells does this table have in all?
<table>
<tr><td>Orange</td><td>Papaya</td></tr>
<tr><td>Papaya</td><td>Jamun</td></tr>
</table> -
35.🔗 Which address opens when you click this link?
<a href="contact.html">Play games</a> (a) maths.html (b) Play games (c) contact.html (d) https://example.com - 36.🧩 Which language makes a link? (a) HTML (b) CSS (c) JavaScript
-
37.📋 How many items does this list show?
<ol>
<li>Guava</li>
<li>Jamun</li>
<li>Banana</li>
<li>Papaya</li>
<li>Litchi</li>
<li>Grapes</li>
</ol> - 38.📋 Which list suits a shopping list in any order? (a) <hr> (b) <ul> (c) <br> (d) <ol>
- 39.✍️ Which sign goes between a property and its value? (a) - (b) = (c) ; (d) :
-
40.📝 How many paragraphs does this code make?
<p>Hello, world!</p>
<p>Good morning!</p>
<p>I love mangoes.</p>
<h2>Rain today</h2>
<h2>I love mangoes.</h2>
Answer key
- for
- 42
- <a href="about.html">
- About us
- script.js
- 2
- if
- an element selector
- blue
- blue
- No
- True
- True
- black
- the body
- 4
- <table>
- 134
- 2
- text
- let
- Welcome, Arjun!
- <h4>
- download from pop-ups
- True
- font-size
- line 3
- <h6>
- 24
- sends the form
- School news
- semantic
- it tells its meaning
- 4
- contact.html
- HTML
- 6
- <ul>
- :
- 3
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids