cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
General C++ Programming
Finding if a number is prime
Finding if a number is prime
Nov 24, 2008 at 1:37am UTC
ctrechter
(8)
Sorry wanted to delete my info but if you need help figuring out a program on prime numbers let me know! I figured it out using
do
for loop
if statement
2nd if statement outside of the loop
else
while
Last edited on
Nov 24, 2008 at 11:45pm UTC
Nov 24, 2008 at 1:41am UTC
helios
(17607)
1
2
3
4
5
6
7
8
9
#include <iostream>
bool
prime(
int
n){
//...
}
int
main(){
//...
}
Topic archived. No new replies allowed.