Skip to content

Latest commit

 

History

History
37 lines (21 loc) · 1.38 KB

File metadata and controls

37 lines (21 loc) · 1.38 KB

Programming with JavaScript: Class 7

Read

MDN Control Flow

Read and Demo

Functions Operators

Skim

Expressions and Operators Functions

1.What is control flow?

The control flow is the order in which the computer executes statements in a script. Control flow means that when you read a script, you must not only read from start to finish but also look at program structure and how it affects order of execution.

2.What is a JavaScript function?

A JavaScript function is a block of code designed to perform a particular task. A JavaScript function is executed when "something" invokes it (calls it).

3.What does it mean to invoke - or call - a function?

The code inside the function will execute when "something" invokes (calls) the function:

  • When an event occurs (when a user clicks a button)
  • When it is invoked (called) from JavaScript code
  • Automatically (self invoked)

4.What are the parenthesis () for when you define a function?

The parentheses may include parameter names separated by commas.

CF Reading Journal Home