Skip to content

Added ToggleKthBit algorithm in bitmanipulation with unit tests. The method toggles the K-th bit of a number using bitwise XOR. Includes an example and JavaDoc. #6299

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

Closed
wants to merge 3 commits into from

Conversation

Rahul-18r
Copy link
Contributor

  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized it.
  • All filenames are in PascalCase.
  • All functions and variable names follow Java naming conventions.
  • All new algorithms have a URL in their comments that points to Wikipedia or other similar explanations.
  • All new code is formatted with clang-format -i --style=file path/to/your/file.java

@DenizAltunkapan
Copy link
Collaborator

unfortunately this one already exists in src/main/java/com/thealgorithms/bitmanipulation/SingleBitOperations.java . @Rahul-18r

@Rahul-18r
Copy link
Contributor Author

Rahul-18r commented Jun 19, 2025 via email

@Rahul-18r
Copy link
Contributor Author

Rahul-18r commented Jun 19, 2025 via email

@DenizAltunkapan
Copy link
Collaborator

Hi @Rahul-18r ,

Thanks for your interest and your thoughtful suggestion! I think, this is not currently the priority. However, I think it could potentially be automated. I will do some reasearch on that.

But if you want to contribute, here is a Task for you: #6300
Thank you!

@Rahul-18r
Copy link
Contributor Author

Rahul-18r commented Jun 19, 2025 via email

@Rahul-18r Rahul-18r closed this by deleting the head repository Jun 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants