Skip to content

Commit 58ed032

Browse files
authored
Merge pull request #2129 from vsemozhetbyt/ch-1-2-9
Address some possible inconsistencies in 1.2.9
2 parents 1f8b72b + 071efd8 commit 58ed032

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

1-js/02-first-steps/09-comparison/1-comparison-questions/solution.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Some of the reasons:
1414

1515
1. Obviously, true.
1616
2. Dictionary comparison, hence false. `"a"` is smaller than `"p"`.
17-
3. Again, dictionary comparison, first char of `"2"` is greater than the first char of `"1"`.
17+
3. Again, dictionary comparison, first char `"2"` is greater than the first char `"1"`.
1818
4. Values `null` and `undefined` equal each other only.
1919
5. Strict equality is strict. Different types from both sides lead to false.
2020
6. Similar to `(4)`, `null` only equals `undefined`.

1-js/02-first-steps/09-comparison/article.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ In JavaScript they are written like this:
99
- Equals: `a == b`, please note the double equality sign `==` means the equality test, while a single one `a = b` means an assignment.
1010
- Not equals. In maths the notation is <code>&ne;</code>, but in JavaScript it's written as <code>a != b</code>.
1111

12-
In this article we'll learn more about different types of comparisons, how JavaScript makes them, including important peculiarities.
12+
In this article we'll learn more about different types of comparisons, how JavaScript makes them, including important peculiarities.
1313

14-
At the end you'll find a good recipe to avoid "javascript quirks"-related issues.
14+
At the end you'll find a good recipe to avoid "JavaScript quirks"-related issues.
1515

1616
## Boolean is the result
1717

@@ -57,7 +57,7 @@ The algorithm to compare two strings is simple:
5757
4. Repeat until the end of either string.
5858
5. If both strings end at the same length, then they are equal. Otherwise, the longer string is greater.
5959

60-
In the examples above, the comparison `'Z' > 'A'` gets to a result at the first step while the strings `"Glow"` and `"Glee"` are compared character-by-character:
60+
In the examples above, the comparison `'Z' > 'A'` gets to a result at the first step while the strings `'Glow'` and `'Glee'` are compared character-by-character:
6161

6262
1. `G` is the same as `G`.
6363
2. `l` is the same as `l`.

0 commit comments

Comments
 (0)