Skip to content

Commit 73f9b7d

Browse files
authored
Fixed mistakes
Hey, please merge my corrections (both grammatical & logical). Great tutorial!
1 parent e0c1904 commit 73f9b7d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tutorial/en/8-Expressions.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ The precedence of operators means we should compute some operators before
1414
others even though the latter may show up first. For example: operator `*`
1515
has higher precedence than operator `+`, so that in expression `2 + 3 * 4`,
1616
the correct calculation result is `2 + (3 * 4)` instead of `(2 + 3) * 4` even
17-
though `+` comes before `+`.
17+
though `+` comes before `*`.
1818

1919
C programming language had already defined the precedence for various
2020
operators, you can refer to [Operator
@@ -27,7 +27,7 @@ we'll get the result through the following steps:
2727
1. push `2` onto the stack.
2828
2. operator `+` is met, push it onto the stack, now we are expecting the other
2929
argument for `+`.
30-
3. `3` is met, push it onto the stack. We are suppose to calculate `2+3`
30+
3. `3` is met, push it onto the stack. We are supposed to calculate `2+3`
3131
immediately, but we are not sure whether `3` belongs to the operator with
3232
higher precedence, so leave it there.
3333
4. operator `-` is met. `-` has the same precedence as `+`, so we are sure
@@ -168,7 +168,7 @@ else if (token == Sizeof) {
168168
}
169169
```
170170

171-
Note that only `sizeof(int)`, `sizeof(char)` and `sizeof(pointer type ...)`
171+
Note that only `sizeof(int)`, `sizeof(char)` (which by the way, is always `1` - by definition) and `sizeof(pointer type ...)`
172172
are supported, and the type of the result is `int`.
173173

174174
### Variable and function invocation

0 commit comments

Comments
 (0)