Solution 1 : Count set bits in a number | while loop | Bit Manipulation Algorithm

preview_player
Показать описание
In this video we will be taking a decimal number and then we will find the number of set bits present in that number. For finding the count of set bits we will make a variable countSetBits and then we will find the binary representation of decimal number. Whenever we get one in the binary representation we will increase the countSetBits variable by one
Комментарии
Автор

Please upload these kind of videos more bro

mohammedsuhailbasha
Автор

What if we have the binary representation and then we have to count the no of set bits?

nikhilrathi
welcome to shbcf.ru