This website works better with JavaScript
Trang chủ
Khám phá
Trợ giúp
Đăng ký
Đăng nhập
wolves
/
leetcode
mirror of
https://git.wolves.top/wolves/leetcode.git
Xem
1
Star
0
Fork
0
Các tập tin
Các vấn đề
0
Wiki
Tree:
e1e872380e
Branches
Tags
main
leetcode
/
26
/
02
/
693.go
693.go
90 B
Lịch sử
Raw
1
2
3
4
5
6
package A
func hasAlternatingBits(n int) bool {
n = n ^ (n >> 1)
return n&(n+1) == 0
}