-
Notifications
You must be signed in to change notification settings - Fork 618
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added Brian Kernighan's algorithm. #43
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only 1 issue to be solved in one or
Remove Sieve code and add another for that
Code/C++/Brian_Kernighan.cpp
Outdated
#include<bits/stdc++.h> | ||
using namespace std; | ||
|
||
// Brian Kernighan's Algorithm |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bring this comment on top of the file
Also, update the readme file for that |
using namespace std; | ||
|
||
|
||
/* It is an algorithm developed to count the number of set bits in a number |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bring this comment outside the main code
Also please link your pr with the issue |
Sir,
I have added Brian Kernighan's algorithm in the Bit Manipulation section. I have explained it very briefly and given the reasoning and intuition behind the algorithm. Please review my pull request, and if you like how I explain then please consider merging it.
I have also been selected in GSSOC'21, and I am really into DSA. So it would be a really kind of you if you give me the opportunity to contribute in this amazing repository.
Regards,
Debanjan Poddar