Skip to Main Content
JavaScript Essentials For Dummies
book

JavaScript Essentials For Dummies

by Paul McFedries
April 2024
Beginner content levelBeginner
192 pages
3h 21m
English
For Dummies
Content preview from JavaScript Essentials For Dummies

Chapter 3

Building Expressions

IN THIS CHAPTER

Bullet Understanding what expressions are

Bullet Figuring out numeric expressions

Bullet Tying up string expressions

Bullet Getting the hang of comparison expressions

Bullet Learning about logical expressions

When coding in JavaScript, you use expressions constantly, so it’s vital to understand what they are and to get comfortable with the types of expressions that are available to you. Every JavaScript coder is different, but I can say without fear of contradiction that every good JavaScript coder is fluent in expressions.

This chapter takes you through everything you need to know about expressions. You discover some expression basics and then explore a number of techniques for building powerful expressions using numbers, strings, and Boolean values.

Understanding How Expressions Are Structured

A JavaScript expression takes one or more inputs, such as a bill total and a tip percentage, and combines them in some way — for example, by using multiplication. In expression ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

JavaScript All-in-One For Dummies

JavaScript All-in-One For Dummies

Chris Minnick

Publisher Resources

ISBN: 9781394263219Purchase Link