True/False
Indicate whether the sentence or statement is true
or false.
|
| 1. | Many
companies use Web sites primarily to market and sell products and services.
|
| 2. | Many
Web site locations are moved constantly; thus, an Internet Explorer favorite Web page available a few
months ago may no longer be valid now.
|
| 3. | Properties are attributes of objects and describe some aspect about the
object.
|
| 4. | Any
time you enter a <SCRIPT> tag, you also must enter a </SCRIPT> tag.
|
| 5. | When
entering JavaScript code, you should pay attention to spelling and placement of quotation marks
because browsers cannot interpret misspelled JavaScript commands.
|
| 6. | HTML
allows automatic links to domain addresses, making it unnecessary for a user to click a reference
link.
|
| 7. | The
navigator object provides the ability to perform calculations.
|
| 8. | Waiting for a Web page generally grabs the attention of visitors and greatly increases
the chance that they will purchase a product from the Web site.
|
| 9. | The
document object actually is a property of the navigator object.
|
| 10. | All
flickers must be coded in the same sequential order so that the screen first displays in red, then
blue, and then green.
|
| 11. | It is
not necessary to set the background color to a final color, once the page flicker is
complete.
|
| 12. | If
you do not close a JavaScript comment, the Web page may display nothing when loaded.
|
| 13. | When
you save an HTML file, you are required to add the .txt extension, because Notepad automatically
saves all files with the default .htm extension.
|
| 14. | Some
browsers have difficulty processing a Web page if it includes spaces in the file name.
|
| 15. | When
saving a file In the Microsoft environment, the file name is case-sensitive and must be entered in
lowercase characters.
|
| 16. | JavaScript variables are broadly typed, which means that you are not required to
define the variable data types as either numeric or character in advance.
|
| 17. | The
statement, var curDate = new Date(), returns tomorrow's system date and time from the computer as an
object instance.
|
| 18. | Since
older browsers have a limit of 255 characters to a line, it is recommended that you break up large
groups of text in a message by using several variables.
|
| 19. | You
can edit an HTML file when Notepad is not the active window on the desktop.
|
| 20. | To
call a function means to have JavaScript execute the function.
|
Multiple Choice
Identify the
letter of the choice that best completes the statement or answers the question.
|
| 21. | Which
of the following objects commonly is used with the fgColor, cookie, and write
properties? a. | window | b. | navigator | c. | math | d. | document | | |
|
| 22. | Which
of the following hides any script language that a browser may not be able to
interpret? a. | numeric
function | b. | <SCRIPT> tags | c. | start
tags | d. | HTML comment
line | | |
|
| 23. | If
you omit the LANGUAGE attribute, most browsers default to which of the following
languages? a. | VBScript | b. | Java | c. | JavaScript | d. | C++ | | |
|
| 24. | Which
of the following refers to JavaScript code written to perform certain tasks
repeatedly? a. | function | b. | method | c. | object | d. | form | | |
|
| 25. | Which
of the following is true regarding naming conventions for functions? a. | it must include
an underscore | b. | it must include a period | c. | it must include
a hyphen | d. | it must begin with a letter | | |
|
| 26. | Which
of the following is defined as a person, place, or thing? a. | method | b. | object | c. | properties | d. | window | | |
|
| 27. | Which
of the following is the general form of an event handler? a. | <TAG
attribute eventHandler = "JavaScript code"> | b. | <TAG
attribute> eventHandler "JavaScript code" | c. | eventHandler =
"JavaScript code" <TAG attribute> | d. | none of the
above | | |
|
| 28. | Which
of the following data types contain logical data as True or False? a. | string | b. | numeric | c. | boolean | d. | alpha | | |
|
| 29. | Which
of the following can be used to modify the header and footer in Notepad? a. | the Notepad
title bar | b. | the View dialog box | c. | the Page Setup
dialog box | d. | the menu bar | | |
|
| 30. | Which
of the following is not an object-oriented language? a. | JavaScript | b. | C++ | c. | Java | d. | none of the above | | |
|
| 31. | Which
of the following objects determines which browser the user is running? a. | window | b. | navigator | c. | document | d. | math | | |
|
| 32. | Which
of the following refers to a variable value that is available only in the function in which it is
defined? a. | global
variable | b. | local variable | c. | inside variable
| d. | none of the
above | | |
|
| 33. | Which
of the following methods causes a delay before an instruction is executed? a. | substring(x,y) | b. | toLocaleString() | c. | setTimeout() | d. | write() | | |
|
| 34. | Which
of the following is a valid function name? a. | get_Payment() | b. | calcPayment()() | c. | verifyForm() | d. | all of the
above | | |
|
| 35. | Which
of the following accomplishes the same effect as using the writeIn() method? a. | inserting
<P> or <BR> tags in the write() method | b. | calling a
JavaScript function | c. | both a. and b. | d. | neither a. nor
b. | | |
|
Completion
Complete each sentence or
statement.
|
| 36. | Notepad automatically saves all files with the default ______________________
extension.
|
| 37. | The
______________________ keyword is required if variables are being defined within a
function.
|
| 38. | To
display the contents of a variable with a text string, you ______________________ the text and the
variable.
|
| 39. | The
time delay specified in the setTimeout method is measured in ______________________.
|
| 40. | A
function name must begin with a ______________________.
|
| 41. | After
a flicker is complete, the background color should be set to a ______________________, or final,
color.
|
| 42. | JavaScript ______________________ are temporary places to store data.
|
| 43. | A
______________________ variable is one whose value is available only in the function in which it is
defined.
|
| 44. | A
______________________ object is a JavaScript object that is neither dependent on nor belongs to
another object.
|
| 45. | The
pow(value, exponent) method is used with the ______________________ object.
|
| 46. | The
______________________ function opens a new window.
|
| 47. | User-defined functions can be called by other JavaScript code or from event handlers
that are ______________________ in the HTML tags.
|
| 48. | To
close your browser, click the Close button on the browser's ______________________.
|
| 49. | One
way to grab visitors' attention while a Web page loads is to use a ______________________,
in
which the background color changes in rapid succession.
|
| 50. | The
method, ______________________, means to raise to the power.
|