wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Web5

Total questions: 35

Worksheet time: 18mins

Name
Class
Date
1.
Display property:
a)
Inline
b)
Background
c)
Color
d)
Text
e)
Number
2.
Assignment operator in Javascript:
a)
-=
b)
&&
c)
/
d)
+
e)
^
3.
Mathematical function of Javascript:
a)
exp(number)
b)
Division()
c)
Plus()
d)
Mines()
e)
Multiplication()
4.
Method of the Date object:
a)
getTime()
b)
sin()
c)
get()
d)
Mines()
e)
Function()
5.
Method of the Date object:
a)
getHours()
b)
sin()
c)
get()
d)
Mines()
e)
Function()
6.
Method of the String object:
a)
length
b)
get()
c)
getHours()
d)
getSeconds()
e)
getMinutes()
7.
Examples of JQuery selectors:
a)
$("p")
b)
%(".par")
c)
*(".par")
d)
&(this)
e)
&("p")
8.
The correct CSS style attribute:
a)
background:oldlace;
b)
background:200px;
c)
font-size:oldlace;
d)
height:oldlace;
e)
font-family:red;
9.
The correct CSS style attribute:
a)
font-family:Arial;
b)
font-color:5;
c)
width:#505050;
d)
height:oldlace;
e)
height:red;
10.
Extension of Javascript:
a)
js
b)
ppt
c)
css
d)
doc
e)
pptx
11.
Correct write "Hello World" in an alert box:
a)
alert(“Hello World”);
b)
msgBox(“Hello World”);
c)
alertBox(“Hello World”);
d)
msg (“Hello World”);
e)
Box(“Hello World”);
12.
Correct creating a function in JavaScript:
a)
function myFunction()
b)
function: myFunction()
c)
function=myFunction()
d)
function && myFunction()
e)
function == myFunction()
13.
Correct write an IF statement in JavaScript:
a)
if (I == 5)
b)
if I = 5
c)
if I == 5 then
d)
if I = 5 then
e)
if I != 5 then
14.
A FOR loop start:
a)
for (i=0; i<=5; i++)
b)
for (i<=5; i++)
c)
for i=1 to 5
d)
for (i=0; i<=5)
e)
for (i=1 to 5)
15.
The correct way to write a JavaScript array:
a)
var colors=["red", «green», «blue»]
b)
var colors=«red», «green», «blue»
c)
var colors=1=(«red»), 2=( «green»), 3=(«blue»)
d)
var colors=(1:»red», 2:»green», 3:»blue»)
e)
var colors=[1:»red», 2:»green», 3:»blue»]
16.
Round the number 7.25, to the nearest integer:
a)
Math.round(7.25)
b)
rnd(7.25)
c)
Math.rnd(7.25)
d)
round(7.25)
e)
Rnd.Math(7.25)
17.
Find the number with the highest value of x and y:
a)
Math.max(x, y)
b)
Math.ceil(x, y)
c)
ceil(x, y)
d)
Math.sin(x, y)
e)
top(x, y)
18.
Declare a JavaScript variable:
a)
var carName;
b)
variable carName;
c)
v carName;
d)
Declare carName;
e)
carName;
19.
Event that occurs when the user clicks on an HTML element:
a)
onclick
b)
onmouseclick
c)
onmouseover
d)
onchange
e)
onmouseout
20.
A WHILE loop start:
a)
while (i <= 10)
b)
while (i <= 10; i++)
c)
while (i <= 10; --i)
d)
while i = 1 to 10
e)
while (i = 0; i<=10)
21.
The ** operator executes:
a)
Raises to the power
b)
Doubles the number
c)
Divides the number by itself
d)
Subtraction
e)
Multiplies the number by itself
22.
Select the JavaScript command that allows you to display text on the page:
a)
document.write('Text output using JavaScript')
b)
write('Text output using JavaScript')
c)
text('Text output using JavaScript')
d)
write.document ('Text output using JavaScript')
e)
text.document ('Text output using JavaScript')
23.
Select the JavaScript command that creates the string variable:
a)
var str=String variable
b)
var str=Array("String variable")
c)
var str=new Object("String variable")
d)
var str=new ("String variable")
e)
var str=new Array("String variable")
24.
Select the syntactically correct command to create a JavaScript object:
a)
var obj=new Object()
b)
var obj=create Object
c)
var obj=call Object
d)
var obj=Object()
e)
var obj=obj Object()
25.

The result of the script:

script language="JavaScript"

s=0;

for (i=1; i<=4; i=i+1)

if ((i%2) ==0) s=s+i;

document. write(s + "<BR>") ;

/SCRIPT

a)
6
b)
0
c)
error
d)
10
e)
2
26.

The result of the script:

script language="JavaScript"

s=0;

for (i=1; i<=10; i=i+1)

if (i/2==0) s=s+i;

document. write(s + "<BR>") ;

/SCRIPT

a)
0
b)
6
c)
error
d)
10
e)
2
27.

The result of the script:

script language="JavaScript"

s=0;

for (i=1; i<=3; i=i+1)

s=s+i;

document. write(s + "<BR>") ;

a)
6
b)
0
c)
error
d)
10
e)
2
28.

Result of the script:

<A href="URL" onmouseover="this.style.color='red'" onmouseout="this.style.color='blue’">LINK</a>

a)
on this page, the hyperlink color changes when you zoom in on the mouse pointer
b)
there is an error on this page, the title and hyperlink properties cannot be changed
c)
on this page, the title properties (color) change
d)
on this page, the background properties (color) change
e)
on this page, when you move the mouse pointer to the title and hyperlink their properties change
29.
Caller property of the Function class performs:
a)
returns a reference to a function that calls the current function
b)
returns the number of arguments required for the function, works anywhere in the program
c)
returns an array of arguments passed to the function, working only in the body of the function
d)
deletes the first element of the array and returns it
e)
deletes the last element of the array and returns it
30.
Function object performs:
a)
consists of lines of JavaScript code that are executed when accessing the object
b)
a set of JavaScript commands defined by the function
c)
consists of simple numeric values that make it easier to work with numeric values
d)
a built-in JavaScript object from which all JavaScript objects are derived
e)
the expression used to search, replace in rows
31.
FunctionBody object performs:
a)
a set of JavaScript commands defined by the& function
b)
consists of lines of JavaScript code that are executed when accessing an object
c)
consists of simple numeric values that make it easier to work with numeric values
d)
a built-in JavaScript object from which all JavaScript objects are derived
e)
the expression used to search, replace in rows
32.
Number object performs:
a)
consists of simple numeric values that make it easier to work with numeric values
b)
a set of JavaScript commands defined by the& function
c)
consists of lines of JavaScript code that are executed when accessing an object
d)
a built-in JavaScript object from which all JavaScript objects are derived
e)
the expression used to search, replace in rows
33.
Object performs:
a)
a built-in JavaScript object from which all JavaScript objects are derived
b)
a set of JavaScript commands defined by the& function
c)
consists of simple numeric values that make it easier to work with numeric values
d)
consists of lines of JavaScript code that are executed when accessing an object
e)
the expression used to search, replace in rows
34.
Image object:
a)
provides access to video and image properties
b)
string that is the addressee of a hypertext link on a html-page
c)
Java-applets located on an HTML page
d)
area on the video card
e)
a sequence of characters that can be part of a string
35.
Layer object:
a)

provides access to layer and Layer Properties

b)
provides access to the link and link properties of the HTML document
c)
an array that stores the URLs that the user viewed in this window
d)
stores information about the screen size and colors
e)
button in HTML form