2
 Ispis prostih brojeva #include <iostream> #include <conio.h> using namespace std; int main() { int i, j, k, n; bool rost ! true; cout << "pisi broj$ "; cin >> n; i ! %; k ! &; 'hile (k < n) { or (j ! ; j <! i*; ++j) { i (ij !! &) {rost ! alse; break;- - i (rost) {cout << i << endl; ++k;- ++i; rost ! true; - getch(); return &; - #include <iostream> using namespace std; int main() { int i,j,k,n; bool rost ! true;

Ispis prostih brojeva

Embed Size (px)

Citation preview

Ispis prostih brojeva

#include

#include

using namespace std;

int main() {

int i, j, k, n;

bool Prost = true;

cout > n;

i = 1;

k = 0;

while (k < n) {

for (j = 2; j