Assessment WS1 7

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 1

Republic of the Philippines

PARTIDO STATE UNIVERSITY


Camarines Sur
PSY-SYL-___-___

Module 7

Assessment

A. Direction: Write TRUE if the statement is correct and FALSE if the statement is incorrect and
underlines the word or expression that makes the statement incorrect.

TRUE 1. JavaScript allows you to work with three primitive data types- numbers, strings, Boolean.

TRUE 2. Variables are declared with the var keyword.


FALSE 3. Arithmetic operators are used to perform arithmetic operations between values or variables
TRUE 4. JavaScript reserved words cannot be used as variables, functions, methods, loop labels, or any
object names.
TRUE 5. The conditional operator first evaluates an expression for a true or false value and then executes
one of the two given statements depending upon the result of the evaluation.

B. Direction: Encircle the letter of the best answer.

1. What is the correct JavaScript syntax to write "Hello World"?


a. response.write("Hello World"); c. echo "Hello World";
b. document.write("Hello World"); d. ("Hello World");
7. Where is the correct place to insert a JavaScript?
a. The <body> section.
b. The <img> section.
c. The <head> section.
d. Both the <head> section and the <body> section are correct.
8. What is the correct syntax for referring to an external script called "xxx.js"?
a. <script src="xxx.js">
b. <script href="xxx.js">
c. <script name="xxx.js">
d. <script type="xxx.js">
9. How do you write "Hello World" in an alert box?
a. msg("Hello World"); c. alertBox("Hello World");
b. msgBox("Hello World"); d. alert("Hello World");
10. What does this operator means &&?
a. Logical AND c. Logical Not
b. Logical OR d. less than

You might also like