Open halfrost opened 3 years ago
https://books.halfrost.com/leetcode/ChapterFour/0200~0299/0231.Power-of-Two/
判断是不是等于lowbit:
func isPowerOfTwo(n int) bool { if n <= 0 { return false } lowbit := n & (-n) return lowbit == n }
https://books.halfrost.com/leetcode/ChapterFour/0200~0299/0231.Power-of-Two/