Skip to content

Commit 65aa85c

Browse files
committed
fix: correct test expectations for CountSetBits
1 parent 18ae426 commit 65aa85c

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

src/test/java/com/thealgorithms/bitmanipulation/CountSetBitsTest.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,13 @@ void testCountSetBitsTen() {
3434

3535
@Test
3636
void testCountSetBitsLargeNumber() {
37-
assertEquals(93, CountSetBits.countSetBits(20));
37+
assertEquals(42, CountSetBits.countSetBits(20)); // Changed from 93 to 42
3838
}
3939

40+
4041
@Test
4142
void testCountSetBitsPowerOfTwo() {
42-
assertEquals(9, CountSetBits.countSetBits(8)); // 2^3
43+
assertEquals(13, CountSetBits.countSetBits(8)); // Changed from 9 to 13
4344
}
4445

4546
@Test

0 commit comments

Comments
 (0)