[FEATURE REQUEST] Adding Randomized Algorithms to the Repository
What would you like to Propose?
Hello everyone,
Until just five days ago, our repository had very few randomized algorithms. If anyone is motivated, they can dive into the topic and implement some interesting randomized algorithms.
Issue details
As examples, i could consider algorithms like:
-
[ ] Randomized Closest Pair Algorithm
-
[x] Randomized Quicksort [solved by @VibhuKhera123 #6234 ]
-
[ ] Randomized Matrix Multiplication Verification, if A* B = C
And many others...
Additional Information
These algorithms are a bit harder to test due to their inherent randomness, but they offer a great opportunity to expand the variety of algorithms in the repository and explore different problem-solving approaches.
If you're interested, feel free to start exploring and contribute! Any contributions would be highly appreciated.
@DenizAltunkapan Hey , can i contribute to this issue sir!
@DenizAltunkapan Hey , can i contribute to this issue sir!
ofc. I am currently not able to assign anyone but everyone can contribute by opening a Pull Request to improve this repository 🔥
here are some other examples. Please first check if they are already implemented in the repo :) :
- [ ] Randomized approximation of Pi
- [x] Karger's Min Cut on graphs [solved by @MuhammadEzzatHBK #6233 ]
- [x] Randomized approximation of Integrals (Monte Carlo) [solved by @MuhammadEzzatHBK #6235 ]
- [ ] Randomized solutions of NP-complete Problems, such as:
- [ ] Randomized solution for the Knapsack Problem
- [ ] Randomized solution for the Traveling Salesman Problem (TSP)
- [ ] Randomized solution for the N-Queens Problem
Hello, I will be working Karger's Min Cut. Thanks!
Hello again, I'll be working on the Monte Carlo Integration. Thanks!
Hello again, I'll be working on the Monte Carlo Integration. Thanks!
Thanks a lot! @MuhammadEzzatHBK
Hello! Has this issue been resolved or can I open a PR
resolved
On Wed, May 28, 2025 at 9:27 AM Jason Ghent @.***> wrote:
jasonghent98 left a comment (TheAlgorithms/Java#6219) https://github.com/TheAlgorithms/Java/issues/6219#issuecomment-2914826787
Hello! Has this issue been resolved or can I open a PR
— Reply to this email directly, view it on GitHub https://github.com/TheAlgorithms/Java/issues/6219#issuecomment-2914826787, or unsubscribe https://github.com/notifications/unsubscribe-auth/A2SMTCL7TTLVPLMEPSQ6GUT3AUX3BAVCNFSM6AAAAAB277C3OCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDSMJUHAZDMNZYG4 . You are receiving this because you were mentioned.Message ID: @.***>
Hello! Has this issue been resolved or can I open a PR
This issue is still open since not all in this issue mentioned algorithms are implemened. There are still some problems missing (not implemented yet). Which of the mentioned problems interests you? @jasonghent98
Good afternoon! I was wondering if I could contribute a solution for the Randomized Closest Pair as requested in the original issue opened. I have already begun implementation. Thank you. @DenizAltunkapan
Good afternoon! I was wondering if I could contribute a solution for the Randomized Closest Pair as requested in the original issue opened. I have already begun implementation. Thank you. @DenizAltunkapan
sure :)
@DenizAltunkapan I can take over the randomized matrix multiplication verification. Just to confirm, are we expecting something straightforward with checks and logic or something a little more nuanced, like Freivalds algorithm?
I guess it depends on the scale of the inputs we would be dealing with
@DenizAltunkapan I can take over the randomized matrix multiplication verification. Just to confirm, are we expecting something straightforward with checks and logic or something a little more nuanced, like Freivalds algorithm?
I guess it depends on the scale of the inputs we would be dealing with
i was exactly thinking about Freivalds algorithm! But if you also want to include other approaches, feel free to go for it :) Totally up to you. @jasonghent98
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contribution!
Hello @DenizAltunkapan , I’ve submitted PR #6339, which adds the Randomized Closest Pair algorithm with proper unit tests as requested in this issue. Would appreciate your review when possible. Thank you!