1. Why is JavaScript relatively easy to learn? Because JavaScript does not have all of the complex rules associated with full
object-oriented languages
2. What is the main characteristic of a programming Programming languages are traditionally compiled, whereas scripting languages are
language that distinguishes it from a scripting language? traditionally interpreted.
3. What step should you take to ensure that your Test your code in various browsers.
JavaScript code runs as expected?
4. JavaScript is a scripting language for adding dynamic interpret the script and return the appropriate responses on the client side browsers,
interactivity to Web pages. You can use JavaScript to: not servers. that would require Node.js
5. Which of the following is the most similar to JavaScript JavaScript is more similar to Python or TypeScript in modern use; previously VB
in purpose and implementation? Script but that was limited to IE
6. Which organization approved JavaScript as an European Computer Manufacturer's Association (ECMA)
international standard in 1997?
7. Using JavaScript you create a "ball" object and specify Methods
that the ball can be thrown kicked bounced inflated or
deflated. What term describes the actions you have
specified for your "ball" object?
8. In which sections of an HTML document can you embed The <head> and/or the <body> sections
JavaScript code?
9. What term is a characteristic of an object that describes Property
the object's attributes?
10. Between which tag pair should you reference an The <script></script> tag pair
external .js file in your HTML document when you want to
add JavaScript from an external text file?
11. How should you embed JavaScript code in an HTML5 You can use a single `<script>` tag with a `src` attribute for external files. Inline
document to which you are also linking an external scripts can be added separately but aren't required
JavaScript file?
12. What is Microsoft's implementation of JavaScript JScript
called?
13. Which statement about scripting languages is true? Scripting languages sometimes provide less functionality than full programming
languages, but are usually easier to learn.
14. What term describes a self-contained programming Object
component that can be used in various situations and in
different places in an application?
15. Which JavaScript method should you use if you want The document.write() method
to write a message to the user in your Web page as the
page loads in the browser?
Grade A+ | Updated
, WGU D278 Scripting & Programming Foundations | Exam Prep
16. A JavaScript rule concerning variables states that the a letter the underscore character ( _ ) or the dollar sign ( $ ).
first character of a variable name must be:
17. Why should you use the JavaScript prompt() method? To create a pop-up box with the specified message string and to request user input
into a text field in the box
18. Which statement is true regarding capitalization and Variable names can be written in lowercase or uppercase, but it is good coding
variable names in JavaScript? practice to use consistent capitalization for all names.
19. What is a variable in JavaScript? A named space of memory that allows you to store a value
20. What kind of data would a Boolean data type store? True or false values only
21. Which JavaScript method should you use if you want The alert() method
to display a message to the user in a popup box when the
user opens your Web page?
23. Consider the following code: var birthYear = "1956" The string data type
What data type does the variable birthYear contain?
24. Which variable data type represents a value of The null data type
"nothing?"
25. What is an expression in JavaScript? A part of a statement that is evaluated as a value
26. In JavaScript how do you combine text strings such as Use concatenation to link two or more text strings.
combining the prompt() and alert() methods to request
user input and then display it?
27. In JavaScript what is a literal? The actual data value you provide in JavaScript
28. In programming what should you use to instruct the An operator
program how to store or evaluate a value?
29. Consider the following expression: apartmentNumber = Assignment
523 What type of expression does this code snippet
represent?
30. What variable data type should you use if you want to The number data type
store numeric values that are to be used in mathematical
calculations?
31. Consider the following expression: "Good morning " + String concatenation expression
"Sarah" What type of expression does this code snippet
represent?
Grade A+ | Updated