You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
아래는 [우선순위 테이블(precedence table)](https://developer.mozilla.org/en/JavaScript/Reference/operators/operator_precedence)의 일부를 발췌한 표입니다. 순서를 기억할 필요는 없지만, 동일한 기호의 단항 연산자는 이항 연산자보다 우선순위가 더 높다는 것에 주목해 주시기 바랍니다.
137
137
138
-
| 순위 | 연산자 이름 | 기호 |
139
-
|------------|------|------|
140
-
|...|...|...|
141
-
|17| 단항 덧셈 |`+`|
142
-
|17| 단항 부정 |`-`|
143
-
|15| 곱셈 |`*`|
144
-
|15| 나눗셈 |`/`|
145
-
|13| 덧셈 |`+`|
146
-
|13| 뺄셈 |`-`|
147
-
|...|...|...|
148
-
|3| 할당 |`=`|
149
-
|...|...|...|
138
+
| 순위 | 연산자 이름 | 기호|
139
+
|---|------|---|
140
+
|...|...|...|
141
+
|17| 단항 덧셈|`+`|
142
+
|17| 단항 부정|`-`|
143
+
|15| 곱셈|`*`|
144
+
|15| 나눗셈|`/`|
145
+
|13| 덧셈|`+`|
146
+
|13| 뺄셈|`-`|
147
+
|...|...|...|
148
+
|3| 할당|`=`|
149
+
|...|...|...|
150
150
151
151
"단항 덧셈 연산자"는 우선순위 `17`으로, "(이항) 덧셈 연산자"의 우선순위 `13`보다 높습니다. 표현식 `"+apples + +oranges"`에서 단항 덧셈 연산자가 덧셈보다 먼저 수행되는 이유가 바로 이 때문입니다.
0 commit comments