---
title: "Discussion on \"#231. Power of Two\" | Hashnode"
description: "Discussion on \"#231. Power of Two\". https://leetcode.com/problems/power-of-two/description/?envType=daily-question&envId=2024-02-19\n/**\n * @param {number} n\n * @return {boolean}\n */\nvar isPowerOfTwo = function(n) {\n    return n > 0 && (n & n - 1) == 0\n};\n\nTo check if a number is a powe..."
url: "https://hashnode.com/posts/231-power-of-two/65d37c5e33dbd9848e45b159"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [#231. Power of Two](https://karleb.hashnode.dev/231-power-of-two?utm_source=hashnode&utm_medium=feed)

https://leetcode.com/problems/power-of-two/description/?envType=daily-question&envId=2024-02-19 /\*\* \* @param {number} n \* @return {boolean} \*/ var isPowerOfTwo = function(n) { return n > 0 && (n & n - 1) == 0 }; To check if a number is a powe...

Feb 19, 2024 · 1 min read · karleb.hashnode.dev  
Read the article

-   [#leetcode](https://hashnode.com/tag/leetcode)

## Written by

[Karleb](https://hashnode.com/@Karleb)

@Karleb · Nigeria

  
[View profile](https://hashnode.com/@Karleb)

I am an enthusiastic web developer

I am a web developer who specializes on the PHP language with Laravel framework and currently developing love for nodejs. I love Javascript and all its frameworks. Tailwind is dope! 😎

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
