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.🛡️ Online: is it safe to share your OTP? (a) safe (b) not safe
- 2.🖼️ Which attribute of <img> tells which image to load? (a) width (b) alt (c) src (d) height
-
3.🔠 How many headings are in this code?
<h1>I love mangoes.</h1>
<p>Good morning!</p>
<h2>Fun facts</h2> - 4.📛 In <a href="x.html">, what is href? (a) a closing tag (b) an attribute (c) a comment (d) an element name
-
5.📝 On how many lines does the browser show this paragraph?
<p>Stars shine<br>Roses are red<br>Sky is blue<br>Kites fly high<br>Birds sing</p> - 6.🎯 Which sign starts an id selector? (a) . (b) & (c) # (d) @
-
7.📝 On how many lines does the browser show this paragraph?
<p>Kites fly high<br>Roses are red<br>Stars shine<br>Rivers flow<br>Birds sing</p> - 8.🖼️ Does <img> need a closing tag? (a) Yes (b) No
-
9.🔠 How many headings are in this code?
<h1>Rain today</h1>
<h4>Our school trip</h4>
<p>Rain today</p> -
10.🔠 How many headings are in this code?
<h1>Our school trip</h1>
<h2>I love mangoes.</h2>
<p>The red kite</p>
<h4>Hello, world!</h4>
<p>I love mangoes.</p> - 11.🔁 When does the else part run? (a) never (b) when if is true (c) always (d) when if is false
- 12.⚖️ Which selector is the weakest? (a) an id selector (b) a class selector (c) an element selector
- 13.🔍 Which is the odd one out? (a) gives the page structure (b) makes a form box (c) lays out the page (d) makes headings and lists
- 14.True or false: <td> makes a heading cell. (a) True (b) False
- 15.True or false: a code editor hosts websites online. (a) False (b) True
- 16.📋 Which list tag lists things in any order? (a) <ul> (b) <li> (c) <ol>
- 17.🌍 Which one is the page’s address? (a) the browser (b) the server (c) HTTPS (d) the URL
- 18.🖌️ Which CSS property makes the text bold? (a) text-align (b) font-weight (c) background-color (d) color
- 19.⚡ Which word makes a new variable? (a) put (b) make (c) let (d) give
- 20.🔐 Is riya2014 a strong or a weak password? (a) weak (b) strong
-
21.🖼️ Which picture file does the browser load?
<img src="dog.jpg" alt="A happy dog" width="350"> (a) dog.jpg (b) A happy dog (c) moon.png (d) bus.jpg - 22.📄 Can HTML on its own make tables? (a) No (b) Yes
-
23.⚖️ What colour is the text of this element?
<h1 class="menu" id="intro">Hi</h1>
CSS:
h1 { color: purple; }
h1 { color: red; } (a) yellow (b) blue (c) purple (d) red -
24.✍️ What is the selector in this CSS rule?
li {
padding: 8px;
font-weight: bold;
} (a) padding (b) body (c) li (d) bold - 25.✍️ In color: blue; which part is the value? (a) ; (b) : (c) color (d) blue
- 26.True or false: “label every form box” helps everyone use the page. (a) True (b) False
- 27.What does font-size do? (a) makes the text bold (b) colours behind the text (c) sets the letter colour (d) makes letters bigger
- 28.🌈 In #000800 the green part is the hex number 08. What is it as a normal number?
- 29.🔍 Which is the odd one out? (a) colours code to help us (b) is where we type code (c) opens web pages for us (d) shows line numbers
- 30.🖼️ Which attribute of <img> sets how tall it is? (a) alt (b) height (c) src (d) width
-
31.✍️ What value is given to font-style in this rule?
p {
font-style: italic;
background-color: yellow;
} (a) italic (b) font-style (c) red (d) 20px - 32.⚡ A JavaScript file usually ends with which extension? (a) .jpg (b) .js (c) .html (d) .css
- 33.Which of these is the content? (a) the text or picture (b) the gap to other boxes (c) space inside the border (d) space outside the border
-
34.🔁 What does this code print?
let marks = 48;
if (marks >= 38) {
console.log("Pass");
} else {
console.log("Try again");
} (a) Try again (b) Pass - 35.🔠 Which tag is the least important heading? (a) <h6> (b) <h3> (c) <p> (d) <h1>
-
36.⚡ What number does this code print?
let a = 13;
let b = 12;
console.log(a - b); - 37.🎯 Can many elements share the same class? (a) No (b) Yes
- 38.✍️ Which sign ends each CSS declaration? (a) : (b) , (c) . (d) ;
- 39.🔍 Which is the odd one out? (a) colours code to help us (b) saves our .html files (c) shows line numbers (d) has an address bar
-
40.📝 How many <input> tags are in this form?
<form>
<input type="password">
<input type="text">
<input type="number">
<input type="checkbox">
<input type="date">
<input type="submit" value="Send">
</form>
Answer key
- not safe
- src
- 2
- an attribute
- 5
- #
- 5
- No
- 2
- 3
- when if is false
- an element selector
- lays out the page
- False
- False
- <ul>
- the URL
- font-weight
- let
- weak
- dog.jpg
- Yes
- red
- li
- blue
- True
- makes letters bigger
- 8
- opens web pages for us
- height
- italic
- .js
- the text or picture
- Pass
- <h6>
- 1
- Yes
- ;
- has an address bar
- 6
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids