Skip to content

Commit a6d1cf3

Browse files
committed
Fix
1 parent 8949aa1 commit a6d1cf3

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/main/java/com/thealgorithms/bitmanipulation/CountLeadingZeros.java

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,15 @@
11
package com.thealgorithms.bitmanipulation;
22

3+
/**
4+
* CountLeadingZeros class contains a method to count the number of leading zeros in the binary representation of a number.
5+
* The number of leading zeros is the number of zeros before the leftmost 1 bit.
6+
* For example, the number 5 has 29 leading zeros in its 32-bit binary representation.
7+
* The number 0 has 32 leading zeros.
8+
* The number 1 has 31 leading zeros.
9+
* The number -1 has no leading zeros.
10+
*
11+
* @author Hardvan
12+
*/
313
public class CountLeadingZeros {
414

515
/**

0 commit comments

Comments
 (0)