Skip to content

Commit 6e0e6ce

Browse files
authored
fix: 运算符优先级bug
1 parent 0195458 commit 6e0e6ce

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

problems/342.power-of-four.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ return num == 1;
7272
代码如下:
7373

7474
```js
75-
return num > 0 && num & (num - 1 === 0) && (num - 1) % 3 === 0;
75+
return num > 0 && (num & (num - 1)) === 0 && (num - 1) % 3 === 0;
7676
```
7777

7878
## 关键点

0 commit comments

Comments
 (0)