GeezerVison is showing github.com — Merge pull request #5 from mambocab/master · encircleacity/javascript@cce8733
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: functions/declare.md +3-3Lines changed: 3 additions & 3 deletions - Display the source diff
- Display the rich diff
| Original file line number | Diff line number | Diff line change |
|---|
|
1 | 1 | # Declaring Functions |
2 | 2 |
|
3 | | -Functions like variables must be declared. Lets declare a function `double` which accepts an **argument** called `x` and **returns** the double of x : |
| 3 | +Functions, like variables, must be declared. Let's declare a function `double` which accepts an **argument** called `x` and **returns** the double of x : |
4 | 4 |
|
5 | 5 | ```javascript |
6 | 6 | function double(x) { |
7 | 7 | return 2 * x; |
8 | 8 | } |
9 | 9 | ``` |
10 | 10 |
|
11 | | -Functions are also values in JavaScript, they can be stored in variables (just like numbers, strings, etc ...) and given to other functions as arguments : |
| 11 | +Functions are also values in JavaScript: they can be stored in variables (just like numbers, strings, etc ...) and given to other functions as arguments : |
12 | 12 |
|
13 | 13 | ```javascript |
14 | 14 | var double = function(x) { |
@@ -18,7 +18,7 @@ var double = function(x) { |
18 | 18 |
|
19 | 19 | --- |
20 | 20 |
|
21 | | -Declare a function named `triple` that takes and argument and returns it's triple. |
| 21 | +Declare a function named `triple` that takes an argument and returns its triple. |
22 | 22 |
|
23 | 23 | ```js |
24 | 24 |
|
|