-
Notifications
You must be signed in to change notification settings - Fork 18.7k
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
[BUG] Optimise the Steve of eratosthenes Algorithm #4129
Comments
i have optimised the algorithm |
I mean to say that the number of lines is quite large I can reduce it to half the size of the current algorithm. @siriak can you assign me this? |
Code was good but i can reduce lines and optimise it.@siriak can you assign me this. |
Please open PRs with the changes you want to make |
@siriak , opened a PR with some changes, please review and suggest if its need any change. |
Hey there! So, here are some steps that can be taken to improve the existing code for Sieve of Eratosthenes algorithm in an informal way: We can replace the 'Type' enum with a boolean array to store the prime numbers' status. This will reduce the memory used and make the code simpler to understand. `
} |
powerful |
Sure! Why not Can you please Assign Me ? A Request |
It can be optimized ,which reduces the length of the code ,Assign it to me? |
Fixed in #4149 |
Description
I was going through the code, that is, the SIEVE OF ERASTOSTHENES Algo and found it was somewhere between 80 82 lines, the code was quite long, can I improve it by reducing the size of the code?
Steps to reproduce
No response
Excepted behavior
The code is performing as expected but it was quite large and lengthy, I would like to shorten the code.
Screenshots
Additional context
No response
The text was updated successfully, but these errors were encountered: