DBA130 Midterm

¡Supera tus tareas y exámenes ahora con Quizwiz!

an instance of the object

A new object created from a constructor function is known as:

A local variable

A variable defined inside a function definition is called

<h1>

Choose the correct HTML element for the largest heading:

<em>

Choose the correct HTML element to define emphasized text

<strong>

Choose the correct HTML element to define important text

var x = 5, y = 7;

Declare two variables x and y and initialize them in the same declaration statement.

Inheritance

Deriving new objects by using the design of currently existing objects is known as:

myString.indexof("is stupid");

For a string called myString containing the value "stupid is as stupid does, " which of the following would return a value of -1?

True

HTML comments start with <!-- and end with -->

<ul>

How can you make a bulleted list?

<ol>

How can you make a numbered list?

Any number

How many <script> elements are permitted on a page?

/documents/letter.html

If my loaded page is http://www.example.com/documents/letter.html?page=2, what will the property of the location.pathname of the location object contain?

window.document.title

In DOM, if you want to access the title property of the current document as specified by the HTML <title>...</title> tages, what is the object notation?

A interpreted language

Is JavaScript a compiled or an interpreted language?

JavaScript Object Notation

JSON is an acronym standing for:

The function name, with parentheses

JavaScript functions are called using:

===

The operator that compares the value and the type is _____.

The window object

The top level of the DOM hierarchy is occupied by:

Curly braces, {}

What character is normally used to enclose the series of parameter:value pairs in a JSON object?

break;

What command forces the cancellation of a loop, and moves code operation to the statement after the closing brace?

Assuming the myhouse object exists, it assigns the value of the kitchen property of the myhouse object to the variable x.

What could you say about the following code: var x = myhouse.kitchen;

Assuming the myhouse object exists, the kitchen property is assigned a new string value of "big" or is initialized with the value "big".

What could you say about the following code? myhouse.kitchen = "big";

Curly brackets

What do you use to enclose the blocks of code in conditionals and loops?

Hyper Text Markup Language

What does HTML stand for?

<script> and </script>

What extra tags must be added to an HTML page to include JavaScript statments?

A value is returned and function execution stops

What happens when a function executes a return statement?

A value of true is returned to the calling program.

What happens when a user clicks OK in a confirm dialog? (use your best guess)

A script that executes in response to the user clicking the mouse

What is an onClick event handler?

<br>

What is the correct HTML element for inserting a line break?

<body style="background-color:yellow;">

What is the correct HTML for adding a background color?

<a href="http://www.w3schools.com">W3Schools</a>

What is the correct HTML for creating a hyperlink?

<img src="image.gif" alt="MyImage">

What is the correct HTML for inserting an image?

<input type="checkbox">

What is the correct HTML for making a checkbox?

<select>

What is the correct HTML for making a drop-down list?

<textarea>

What is the correct HTML for making a text area?

<input type="text">

What is the correct HTML for making a text input field?

break;

What statement do you use so that the execution does not fall from one case to the next?

string1.concat(string2);

What statement would return a new string created by appending one string called string2 to another string called string1?

alt

Which HTML attribute specifies an alternate text for an image, if the image cannot be displayed?

<title>

Which HTML element defines the title of a document?

/

Which character is used to indicate an end tag?

Math.ceil()

Which method of the Math() object always rounds a number up to the nearest integer?

Their names may contain spaces.

Which of following is NOT true statement about variables?

Directly instantiate an object

Which of the following can you do with JSON?

myObject = new Object();

Which of the following is a valid way to create a direct instance of an object?

The condition to terminate the loop is never met.

Which of the following is likely to cause an infinite loop to occur?

window.alert("You are using " + navigator.appName);

Which of the following would send an alert to the viewer that tells the name of the browser being used?

<table><tr><td>

Which of these elements are all <table> elements?

var paid = true;

Which statement sets the value of variable paid to Boolean true?

//

Which syntax do you use for a single line comment in JavaScript?

The World Wide Web Consortium

Who is making the Web standards?

Brendan Eich

Who is the one that created JavaScript language?

objectName.methodName();

You access an object method with the following syntax:

False

You use the = operator to test whether two variables are equal.


Conjuntos de estudio relacionados

Chapter 1 Video Exercise: Southwest Airlines

View Set

Photosynthesis and Cellular Respiration

View Set

Science Unit 1 - Quiz 2: Plant Systems

View Set