Coder Profile - Show off your skills, get a coder profile.
 
 
 
The Author
thetrojan01
Lucas X.
Send A Message
Rating
Not
Rated
Please login to rate source codes.

Click here to register a free account with us.
General Details
C++
Posted 250 Days Ago
218 Views
Received 0 Ratings
More Codes By This Author
Prime Number Finder - C/C...
Prime Number Finder - Jav...
Simple PHP port scanner (...
[perl] [*nix] Uptime
Make'EmCaps
Articles By This Author
How to fix scratched cds...
thetrojan01's brainfuck t...

Prime Number Finder - C/C++ Version


Description
Prime Numbers Finder using the Sieve of Eratosthenes

User gives a natural number (positive integer) N from the standard input and the program writes 2 lines: It calculates all the prime numbers up to N in one line, and in the last line, it writes how many they are.
Technical
This is the C/C++ Version. I think it compiles both in C and C++.

I recommend GCC or G++ as a compiler. Personally I compiled it like this:

g++ sieve.cpp -O3 -o sieve
Source Code
Comments
Please login to post comments.
Page 1 of 1
More "C++" Source Codes By This Author
Recently Posted "C++" Source Codes
Recently Rated "C++" Source Codes
 
 
Latest News About Coder Profile
Coder Profile Poll
Which sounds better on your coder profiles, and makes more sense to you (think twitter, facebook, etc)?

Followers / Following
Fans / Following
Fans / Fan Of


please login to cast your vote
and see the results of this poll
Latest Coder Profile Changes
Coder Profile was last updated
1.28 Year Ago
Official Blog :: Make A Donation :: Credits :: Contact Me
Terms & Conditions :: Privacy Policy :: Documents :: Wallpapers
Version 1.46.00
Copyright © 2007 - 2010, Scott Thompson, All Rights Reserved