Click here to Skip to main content
Click here to Skip to main content
Add your own
alternative version

Tagged as

Find Prime Numbers in C# Using the Sieve of Eratosthenes

, 12 Sep 2011 CPOL
Here's an alternative. This one uses the BitArray class in C# and does not use the % operator.static List SeiveWithoutMod(int candidate){ BitArray sieveContainer = new BitArray(candidate + 1, true); int marker = 2; //start int factor = 2; //start. sieveContainer[0]...

Statistics


License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Bill Anderson
Web Developer
United States United States
Developer

| Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.141223.1 | Last Updated 12 Sep 2011
Article Copyright 2011 by Bill Anderson
Everything else Copyright © CodeProject, 1999-2014
Layout: fixed | fluid