/BinaryGap

Primary LanguageJavaScript

Given a positive integer n, find the maximal sequence of consecutive zeros that is surrounded by ones at both ends in the binary representation of n