O'Reilly logo

Internet & World Wide Web: How to Program, Fifth Edition by Abbey Deitel, Harvey Deitel, Paul Deitel

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

6. JavaScript: Introduction to Scripting

Comment is free, but facts are sacred.

—C. P. Scott

The creditor hath a better memory than the debtor.

—James Howell

When faced with a decision, I always ask, “What would be the most fun?”

—Peggy Walker

Objectives

In this chapter you will:

• Write simple JavaScript programs.

• Use input and output statements.

• Learn basic memory concepts.

• Use arithmetic operators.

• Learn the precedence of arithmetic operators.

• Write decision-making statements to choose among alternative courses of action.

• Use relational and equality operators to compare data items.

Outline

6.1 Introduction

6.2 Your First Script: Displaying a Line of Text with JavaScript in a Web Page

6.3 Modifying Your First Script

6.4 Obtaining ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required