Wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

SEM 1 2021 QUIZ 1 (5%) - Chapter 1 - 7

Total questions: 20

Worksheet time: 9mins

Name
Class
Date
1.

In jQuery, which of the following is selected by $('.foo')?

a)

<p>Foo</p>

b)

<img id='foo'></img>

c)

<div class='foo'></div>

d)

<foo></foo>

2.

In jQuery, which of the following is selected by $('.foo')?

a)

<p>Foo</p>

b)

<img id='foo'></img>

c)

<div class='foo'></div>

d)

<foo></foo>

3.

In jQuery, the "#" is used to select an html element by its:

a)

class

b)

id

c)

name

d)

data attribute

4.

How do I declare a new variable in javaScript?

a)

var newVariable = 5

b)

Variable int = new Variable()

c)

var 5 = myVariable

d)

int var = 5

5.

Choose the right Javascript event

a)

inmouseout

b)

anmouseout

c)

enmouseout

d)

onmouseout

6.

What is the extension for a JavaScript file?

a)

.java

b)

.jar

c)

.js

d)

.sj

7.

Choose the best syntax to write conditional statement for

"His name is Fred and he is less than 16 years old".

a)

if (name = "fred" && age < 16 )

b)

if (name === "fred" && age < 16 )

c)

if (name = "fred" || age < 16 )

d)

if (name === "fred" || age < 16 )

8.

Which of these is a loop?

a)

if(x<10)

b)

while(x<10)

c)

var x=10;

d)

text(x,10;10)

9.

Which of these is part of the Box model of CSS?

a)

div

b)

p

c)

tag

d)

padding

10.

What does this mean:

A:hover { color: blue; }

a)

Links are blue when you hover over them

b)

Animations are blue when you hover over them

c)

The background colour of the body is blue when hovered

d)

There is no blue allowed on the page

11.

Which CSS code will change the background colour of a web page?

a)

backroundColor: blue;

b)

background-color: blue;

c)

background color: blue;

d)

color: blue;

12.

What type of software/app do you need on a computer to view web pages?

a)

Camera

b)

Web Browser

c)

Web Server

d)

Text Editor

13.

A collection of web pages is called a_____

a)

web server

b)

web browser

c)

website

d)

WiFi

14.

Which code below is correct for a hyperlink?

a)

<a>

"https://google.com"

Click Me

</a>

b)

<a>Click Me>

"https://google.com"

</a>

c)

<a herf="https://google.com">

Click Me

</a>

d)

<a href="https://www.google.com">

Click Me

</a>

15.

An attribute is a _____________

a)

Applies changes to everything

b)

Different options for each tag

c)

Allows for no changes to the site

d)

Gives structure and text

16.

<style> tags are used to______

a)

Apply style to one line

b)

Not used in HTML

c)

Used at the top of the page to apply a style to the entire document

d)

Used sparingly

17.

Write css syntax to display hyperlinks without an underline.


a { (a)   }

18.

Write css syntax to display paragraph in italic.


p { (a)   }

19.

Complete below code to hide an element with id="test".


$("_? (a)   ").hide();

20.

A (a)   is used to tells the browser how to display our content.