Skip to content

Commit

Permalink
leetcode
Browse files Browse the repository at this point in the history
  • Loading branch information
jo-ui authored Dec 11, 2022
1 parent f363483 commit b639781
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions 0231-power-of-two/0231-power-of-two.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*/
const isPowerOfTwo = (x) => {
if (x <= 0) {
return false
return false;
}
return (x & (x - 1)) === 0
}
}

0 comments on commit b639781

Please sign in to comment.